{"action":"created","issue":{"url":"https://api.github.com/repos/geany/geany/issues/1121","repository_url":"https://api.github.com/repos/geany/geany","labels_url":"https://api.github.com/repos/geany/geany/issues/1121/labels{/name}","comments_url":"https://api.github.com/repos/geany/geany/issues/1121/comments","events_url":"https://api.github.com/repos/geany/geany/issues/1121/events","html_url":"https://github.com/geany/geany/issues/1121","id":164177990,"number":1121,"title":"Colon styling in Ruby lexer","user":{"login":"TiZ-EX1","id":4130673,"avatar_url":"https://avatars.githubusercontent.com/u/4130673?v=3","gravatar_id":"","url":"https://api.github.com/users/TiZ-EX1","html_url":"https://github.com/TiZ-EX1","followers_url":"https://api.github.com/users/TiZ-EX1/followers","following_url":"https://api.github.com/users/TiZ-EX1/following{/other_user}","gists_url":"https://api.github.com/users/TiZ-EX1/gists{/gist_id}","starred_url":"https://api.github.com/users/TiZ-EX1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TiZ-EX1/subscriptions","organizations_url":"https://api.github.com/users/TiZ-EX1/orgs","repos_url":"https://api.github.com/users/TiZ-EX1/repos","events_url":"https://api.github.com/users/TiZ-EX1/events{/privacy}","received_events_url":"https://api.github.com/users/TiZ-EX1/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/geany/geany/labels/bug","name":"bug","color":"e11d21"},{"url":"https://api.github.com/repos/geany/geany/labels/scintilla","name":"scintilla","color":"bfe5bf"},{"url":"https://api.github.com/repos/geany/geany/labels/waiting%20for%20information","name":"waiting for information","color":"5319e7"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-07-06T21:25:36Z","updated_at":"2016-07-07T21:39:43Z","closed_at":null,"body":"I've noticed a peculiarity in regards to how the Ruby lexer styles colons. A literal that starts with a colon is of course a symbol, but colons are used in other contexts as well, most notably for hash literals, like this snippet from the Ruby docs:\r\n\r\n```ruby\r\noptions = { font_size: 10, font_family: \"Arial\" }\r\n```\r\n\r\nIf you put this in Geany, it will style the colons as symbol literals and not as operators as it should.\r\n\r\nThis is more important for the Ruby-like static language Crystal, in which the Ruby lexer is almost totally sufficient--aside from the fact it only supports primary keywords and not secondary, class, or type keywords--where this notation is used for named tuples, as well as for type annotation for functions: `def square(n: Int32): Int32`\r\n\r\nTL;DR: A colon at the start of a word should indicate a symbol literal, but a colon by itself or at the end of a word should be styled as an operator or punctuation."},"comment":{"url":"https://api.github.com/repos/geany/geany/issues/comments/231215537","html_url":"https://github.com/geany/geany/issues/1121#issuecomment-231215537","issue_url":"https://api.github.com/repos/geany/geany/issues/1121","id":231215537,"user":{"login":"b4n","id":793526,"avatar_url":"https://avatars.githubusercontent.com/u/793526?v=3","gravatar_id":"","url":"https://api.github.com/users/b4n","html_url":"https://github.com/b4n","followers_url":"https://api.github.com/users/b4n/followers","following_url":"https://api.github.com/users/b4n/following{/other_user}","gists_url":"https://api.github.com/users/b4n/gists{/gist_id}","starred_url":"https://api.github.com/users/b4n/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/b4n/subscriptions","organizations_url":"https://api.github.com/users/b4n/orgs","repos_url":"https://api.github.com/users/b4n/repos","events_url":"https://api.github.com/users/b4n/events{/privacy}","received_events_url":"https://api.github.com/users/b4n/received_events","type":"User","site_admin":false},"created_at":"2016-07-07T21:39:43Z","updated_at":"2016-07-07T21:39:43Z","body":"That would be perfect :)"}}
{"actor":{"display_login":"b4n"}}