{"action":"created","issue":{"url":"https://api.github.com/repos/akhodakivskiy/VimFx/issues/803","repository_url":"https://api.github.com/repos/akhodakivskiy/VimFx","labels_url":"https://api.github.com/repos/akhodakivskiy/VimFx/issues/803/labels{/name}","comments_url":"https://api.github.com/repos/akhodakivskiy/VimFx/issues/803/comments","events_url":"https://api.github.com/repos/akhodakivskiy/VimFx/issues/803/events","html_url":"https://github.com/akhodakivskiy/VimFx/pull/803","id":173621211,"number":803,"title":"WIP hints text mode","user":{"login":"lydell","id":2142817,"avatar_url":"https://avatars.githubusercontent.com/u/2142817?v=3","gravatar_id":"","url":"https://api.github.com/users/lydell","html_url":"https://github.com/lydell","followers_url":"https://api.github.com/users/lydell/followers","following_url":"https://api.github.com/users/lydell/following{/other_user}","gists_url":"https://api.github.com/users/lydell/gists{/gist_id}","starred_url":"https://api.github.com/users/lydell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lydell/subscriptions","organizations_url":"https://api.github.com/users/lydell/orgs","repos_url":"https://api.github.com/users/lydell/repos","events_url":"https://api.github.com/users/lydell/events{/privacy}","received_events_url":"https://api.github.com/users/lydell/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":10,"created_at":"2016-08-27T23:48:09Z","updated_at":"2016-08-28T18:59:11Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/akhodakivskiy/VimFx/pulls/803","html_url":"https://github.com/akhodakivskiy/VimFx/pull/803","diff_url":"https://github.com/akhodakivskiy/VimFx/pull/803.diff","patch_url":"https://github.com/akhodakivskiy/VimFx/pull/803.patch"},"body":"Here is my attempt at fixing #340, heavily inspired by @doy’s #789. A few differences compared to that PR:\r\n\r\n- Implements the idea that all hint chars are treated as uppercase in text mode.\r\n\r\n- Ignores text mode for the `eb` command.\r\n\r\n- Treats uppercase typed chars as lowercase in non-text mode. This allows text mode users to type uppercase hint chars in `eb` out of habit.\r\n\r\n- When typing a char that gets matched against element text, the new hints for all matching elements are calculated differently than in other cases. The hints are chosen based on a scoring system (from best hint to worst):\r\n\r\n  1. Match at the beginning of the text.\r\n  2. Match at the beginning of the text, pass 2 elements.\r\n  3. Match at the beginning of a word.\r\n  4. Match at the beginning of a word, pass 2 elements.\r\n  5. Other substring match.\r\n  6. Other substring match, pass 2 elements.\r\n\r\n- Ignores the `ignore_keyboard_layout` option when typing chars to match against element text.\r\n\r\n- Doesn’t treat pressing for example `<delete>` as typing the characters `<delete>`.\r\n\r\n- No-ops when typing a char that results in zero matches.\r\n\r\n- Only ignores keypresses for `hints_timeout` milliseconds if a hint was activated by matching its text.\r\n\r\n- Normalizes whitespace of elements.\r\n\r\n- Ignores spaces when matching element text, unless you explicitly type a space (which requires remapping the default `<space>` shortcut).\r\n\r\n@doy, @progandy, @Tunous, @e12e, @erjoalgo, @frangio please test this PR if you can!\r\n\r\nTODO:\r\n\r\n- More testing.\r\n- Documentation.\r\n- Decide if the `hints_text_mode` pref should be in VimFx’s settings page in the Add-ons Manager or not.\r\n- Figure out if this is what people want, or if something is missing. EDIT: Here’s a list of potential stuff that has been mentioned below:\r\n  - “Pentadactyl space handling”\r\n  - Hint marker placement improvements (see screenshots below)\r\n  - Image alt text matching (shown in the hint marker)"},"comment":{"url":"https://api.github.com/repos/akhodakivskiy/VimFx/issues/comments/242992498","html_url":"https://github.com/akhodakivskiy/VimFx/pull/803#issuecomment-242992498","issue_url":"https://api.github.com/repos/akhodakivskiy/VimFx/issues/803","id":242992498,"user":{"login":"lydell","id":2142817,"avatar_url":"https://avatars.githubusercontent.com/u/2142817?v=3","gravatar_id":"","url":"https://api.github.com/users/lydell","html_url":"https://github.com/lydell","followers_url":"https://api.github.com/users/lydell/followers","following_url":"https://api.github.com/users/lydell/following{/other_user}","gists_url":"https://api.github.com/users/lydell/gists{/gist_id}","starred_url":"https://api.github.com/users/lydell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lydell/subscriptions","organizations_url":"https://api.github.com/users/lydell/orgs","repos_url":"https://api.github.com/users/lydell/repos","events_url":"https://api.github.com/users/lydell/events{/privacy}","received_events_url":"https://api.github.com/users/lydell/received_events","type":"User","site_admin":false},"created_at":"2016-08-28T18:59:11Z","updated_at":"2016-08-28T18:59:11Z","body":"@doy The point of the text mode is to know what to type before seeing the hints, right? That’s not the case for image alt text, so I don’t see how that’s any more useful than simply typing its hint. It just sounds like it might generate lots of really large hint marker that might obscure other things."}}
{"actor":{"display_login":"lydell"}}