{"action":"closed","number":504,"pull_request":{"url":"https://api.github.com/repos/openlayers/ol2/pulls/504","id":1472306,"html_url":"https://github.com/openlayers/ol2/pull/504","diff_url":"https://github.com/openlayers/ol2/pull/504.diff","patch_url":"https://github.com/openlayers/ol2/pull/504.patch","issue_url":"https://api.github.com/repos/openlayers/ol2/issues/504","number":504,"state":"closed","locked":false,"title":"KML: export style","user":{"login":"probins","id":283514,"avatar_url":"https://avatars.githubusercontent.com/u/283514?v=3","gravatar_id":"","url":"https://api.github.com/users/probins","html_url":"https://github.com/probins","followers_url":"https://api.github.com/users/probins/followers","following_url":"https://api.github.com/users/probins/following{/other_user}","gists_url":"https://api.github.com/users/probins/gists{/gist_id}","starred_url":"https://api.github.com/users/probins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/probins/subscriptions","organizations_url":"https://api.github.com/users/probins/orgs","repos_url":"https://api.github.com/users/probins/repos","events_url":"https://api.github.com/users/probins/events{/privacy}","received_events_url":"https://api.github.com/users/probins/received_events","type":"User","site_admin":false},"body":"Builds on http://trac.osgeo.org/openlayers/ticket/2409 with the following additions/changes:\n1. stores incoming document-level 'shared' styles and stylemaps so they can be output as input\n2. if feature has attributes.styleUrl this will be output (and assumed to refer to a stored style)\n3. if no styleUrl, Placemark style will be created specific to feature\n4. named colors ('blue', 'red' etc) catered for by cross-reference object which developers can supply as they wish (I decided this was better than providing a large object with all colors, as most sites won't use most colors)\n\nOpen issues:\n- shared styles are in Document element, which means the Folder element output at the moment is now redundant. I would prefer to get rid of this, but name/description are currently API properties. If people want to keep the Folder for bc, a possible compromise would be to add code not to output if name null\n- as noted in the patch on trac, current OL code should be updated to kml 2.2. I'll look into this and put in separate pull request\n- OL style (at least if you use the defaults) returns a symbolizer which caters for all geometry types. It would reduce the output file size if the feature style only output the style for the geometry type. I've left that for someone else to do if they like :-)\n\nTests which compare output will have to be changed, but I have left that pending decision on what to do with folder. I can add a few basic style output tests, but there are so many different variations and combinations that it's impossible to test everything.\nI have tested with some test data of my own, plus with live data. I have also uploaded output to maps.google.com, made changes, downloaded to OL, changed, re-uploaded and back again, and have not noticed any problems. It would be good, though, if others could test this with their own data to see if there are issues.\n\nI have changed vector-formats example as in trac patch, and you can use this for testing, though if you want to test the output of saved style elements you'll have to copy the saved styles from formats.in.kml to formats.out.kml","created_at":"2012-06-01T09:48:27Z","updated_at":"2016-04-13T11:01:54Z","closed_at":"2016-04-13T11:01:54Z","merged_at":null,"merge_commit_sha":"c19cd01badd96d09f7ef14ac174359143f5d1b67","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/openlayers/ol2/pulls/504/commits","review_comments_url":"https://api.github.com/repos/openlayers/ol2/pulls/504/comments","review_comment_url":"https://api.github.com/repos/openlayers/ol2/pulls/comments{/number}","comments_url":"https://api.github.com/repos/openlayers/ol2/issues/504/comments","statuses_url":"https://api.github.com/repos/openlayers/ol2/statuses/d08629d6b991ebdf5138ab63ece60865c45d099e","head":{"label":"probins:kmlstyle","ref":"kmlstyle","sha":"d08629d6b991ebdf5138ab63ece60865c45d099e","user":{"login":"probins","id":283514,"avatar_url":"https://avatars.githubusercontent.com/u/283514?v=3","gravatar_id":"","url":"https://api.github.com/users/probins","html_url":"https://github.com/probins","followers_url":"https://api.github.com/users/probins/followers","following_url":"https://api.github.com/users/probins/following{/other_user}","gists_url":"https://api.github.com/users/probins/gists{/gist_id}","starred_url":"https://api.github.com/users/probins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/probins/subscriptions","organizations_url":"https://api.github.com/users/probins/orgs","repos_url":"https://api.github.com/users/probins/repos","events_url":"https://api.github.com/users/probins/events{/privacy}","received_events_url":"https://api.github.com/users/probins/received_events","type":"User","site_admin":false},"repo":null},"base":{"label":"openlayers:master","ref":"master","sha":"d431b504bd32edfebf6db11692fb78e4c121d709","user":{"login":"openlayers","id":240579,"avatar_url":"https://avatars.githubusercontent.com/u/240579?v=3","gravatar_id":"","url":"https://api.github.com/users/openlayers","html_url":"https://github.com/openlayers","followers_url":"https://api.github.com/users/openlayers/followers","following_url":"https://api.github.com/users/openlayers/following{/other_user}","gists_url":"https://api.github.com/users/openlayers/gists{/gist_id}","starred_url":"https://api.github.com/users/openlayers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openlayers/subscriptions","organizations_url":"https://api.github.com/users/openlayers/orgs","repos_url":"https://api.github.com/users/openlayers/repos","events_url":"https://api.github.com/users/openlayers/events{/privacy}","received_events_url":"https://api.github.com/users/openlayers/received_events","type":"Organization","site_admin":false},"repo":{"id":2407157,"name":"ol2","full_name":"openlayers/ol2","owner":{"login":"openlayers","id":240579,"avatar_url":"https://avatars.githubusercontent.com/u/240579?v=3","gravatar_id":"","url":"https://api.github.com/users/openlayers","html_url":"https://github.com/openlayers","followers_url":"https://api.github.com/users/openlayers/followers","following_url":"https://api.github.com/users/openlayers/following{/other_user}","gists_url":"https://api.github.com/users/openlayers/gists{/gist_id}","starred_url":"https://api.github.com/users/openlayers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openlayers/subscriptions","organizations_url":"https://api.github.com/users/openlayers/orgs","repos_url":"https://api.github.com/users/openlayers/repos","events_url":"https://api.github.com/users/openlayers/events{/privacy}","received_events_url":"https://api.github.com/users/openlayers/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/openlayers/ol2","description":"OpenLayers 2","fork":false,"url":"https://api.github.com/repos/openlayers/ol2","forks_url":"https://api.github.com/repos/openlayers/ol2/forks","keys_url":"https://api.github.com/repos/openlayers/ol2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/openlayers/ol2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/openlayers/ol2/teams","hooks_url":"https://api.github.com/repos/openlayers/ol2/hooks","issue_events_url":"https://api.github.com/repos/openlayers/ol2/issues/events{/number}","events_url":"https://api.github.com/repos/openlayers/ol2/events","assignees_url":"https://api.github.com/repos/openlayers/ol2/assignees{/user}","branches_url":"https://api.github.com/repos/openlayers/ol2/branches{/branch}","tags_url":"https://api.github.com/repos/openlayers/ol2/tags","blobs_url":"https://api.github.com/repos/openlayers/ol2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/openlayers/ol2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/openlayers/ol2/git/refs{/sha}","trees_url":"https://api.github.com/repos/openlayers/ol2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/openlayers/ol2/statuses/{sha}","languages_url":"https://api.github.com/repos/openlayers/ol2/languages","stargazers_url":"https://api.github.com/repos/openlayers/ol2/stargazers","contributors_url":"https://api.github.com/repos/openlayers/ol2/contributors","subscribers_url":"https://api.github.com/repos/openlayers/ol2/subscribers","subscription_url":"https://api.github.com/repos/openlayers/ol2/subscription","commits_url":"https://api.github.com/repos/openlayers/ol2/commits{/sha}","git_commits_url":"https://api.github.com/repos/openlayers/ol2/git/commits{/sha}","comments_url":"https://api.github.com/repos/openlayers/ol2/comments{/number}","issue_comment_url":"https://api.github.com/repos/openlayers/ol2/issues/comments{/number}","contents_url":"https://api.github.com/repos/openlayers/ol2/contents/{+path}","compare_url":"https://api.github.com/repos/openlayers/ol2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/openlayers/ol2/merges","archive_url":"https://api.github.com/repos/openlayers/ol2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/openlayers/ol2/downloads","issues_url":"https://api.github.com/repos/openlayers/ol2/issues{/number}","pulls_url":"https://api.github.com/repos/openlayers/ol2/pulls{/number}","milestones_url":"https://api.github.com/repos/openlayers/ol2/milestones{/number}","notifications_url":"https://api.github.com/repos/openlayers/ol2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/openlayers/ol2/labels{/name}","releases_url":"https://api.github.com/repos/openlayers/ol2/releases{/id}","deployments_url":"https://api.github.com/repos/openlayers/ol2/deployments","created_at":"2011-09-17T23:02:10Z","updated_at":"2016-04-12T08:17:45Z","pushed_at":"2016-03-21T09:36:26Z","git_url":"git://github.com/openlayers/ol2.git","ssh_url":"git@github.com:openlayers/ol2.git","clone_url":"https://github.com/openlayers/ol2.git","svn_url":"https://github.com/openlayers/ol2","homepage":"http://openlayers.org/two/","size":18722,"stargazers_count":1480,"watchers_count":1480,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":802,"mirror_url":null,"open_issues_count":535,"forks":802,"open_issues":535,"watchers":1480,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/openlayers/ol2/pulls/504"},"html":{"href":"https://github.com/openlayers/ol2/pull/504"},"issue":{"href":"https://api.github.com/repos/openlayers/ol2/issues/504"},"comments":{"href":"https://api.github.com/repos/openlayers/ol2/issues/504/comments"},"review_comments":{"href":"https://api.github.com/repos/openlayers/ol2/pulls/504/comments"},"review_comment":{"href":"https://api.github.com/repos/openlayers/ol2/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/openlayers/ol2/pulls/504/commits"},"statuses":{"href":"https://api.github.com/repos/openlayers/ol2/statuses/d08629d6b991ebdf5138ab63ece60865c45d099e"}},"merged":false,"mergeable":false,"mergeable_state":"dirty","merged_by":null,"comments":1,"review_comments":0,"commits":1,"additions":276,"deletions":8,"changed_files":3}}