Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix paper tape regression #1451

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions news.d/feature/1451.ui.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Improve accessibility:
- Disable tab-key navigation in tables, so focusing a table does not lock global tab-key navigation to it.
- Remove some container widgets, tweak focus rules to avoid extra unnecessary steps when using tab-key navigation (like selecting the dictionaries widget outer frame).
- In form layouts, link each widget to its label (like each option in the configuration dialog).
- Set the accessible name / description of focusable widgets.
- Use lists for the dictionaries widget, suggestions widget, and the paper tape.
9 changes: 2 additions & 7 deletions plover/gui_qt/paper_tape.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,12 +67,6 @@ def _paper_format(self, stroke):
def _raw_format(stroke):
return stroke.rtfcre

def headerData(self, section, orientation, role):
if (section != 0 or orientation != Qt.Horizontal or
role != Qt.DisplayRole or self._style != STYLE_PAPER):
return None
return self._all_keys

def data(self, index, role):
if not index.isValid():
return None
Expand Down Expand Up @@ -163,7 +157,8 @@ def _save_state(self, settings):

def on_config_changed(self, config):
if 'system_name' in config:
self._model.reset()
all_keys = self._model.reset()
self.header.setText(all_keys)

@property
def _scroll_at_end(self):
Expand Down