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

Update Preferences dialog #1149

Merged
merged 1 commit into from Feb 15, 2022

Conversation

DaveSch-gramps
Copy link
Contributor

@DaveSch-gramps DaveSch-gramps commented Nov 10, 2020

Feature Request #12049

Clean up of existing Preferences Tabs

DaveSch-gramps added a commit to DaveSch-gramps/addons-source that referenced this pull request Nov 10, 2020
Brings Themes _panel tabs into agreement with Pull

gramps-project/gramps#1149
@DaveSch-gramps
Copy link
Contributor Author

gramps-project/addons-source#472

Brings Themes into agreement in the _panel Tabs structure.

@DaveSch-gramps
Copy link
Contributor Author

DaveSch-gramps commented Nov 10, 2020 via email

@DaveSch-gramps
Copy link
Contributor Author

NOTE: There is a pull to install icons to the toolbar that IF merged will have added settings to configure.py

#1139

IF that pull is merged, those additional settings will need to be added to this reworking of configure.py

    row += 1
    # Show Plugins Icon:
    self.add_checkbox(
        grid, _("Show Plugins icon on toolbar *"),
        row, 'interface.toolbar-plugin', start=0, stop=3,
        tooltip=_("Show or hide the Plugins icon on the toolbar.\n"
                  "Requires Gramps restart to apply."))

    row += 1
    # Show Preferences icon:
    self.add_checkbox(
        grid, _("Show Preferences icon on toolbar *"),
        row, 'interface.toolbar-preference', start=0, stop=3,
        tooltip=_("Show or hide the Preferences icon on the toolbar.\n"
                  "Requires Gramps restart to apply."))

I post this so more than myself can be aware of this.

@codecov-io
Copy link

Codecov Report

Merging #1149 (e456286) into master (c567b9e) will decrease coverage by 0.12%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1149      +/-   ##
==========================================
- Coverage   41.28%   41.16%   -0.13%     
==========================================
  Files        1060     1062       +2     
  Lines      143397   144645    +1248     
==========================================
+ Hits        59204    59538     +334     
- Misses      84193    85107     +914     
Impacted Files Coverage Δ
gramps/gui/configure.py 0.00% <0.00%> (ø)
gramps/plugins/webreport/narrativeweb.py 74.43% <0.00%> (-2.69%) ⬇️
gramps/plugins/webreport/place.py 68.57% <0.00%> (-2.62%) ⬇️
gramps/gen/utils/image.py 14.85% <0.00%> (-1.64%) ⬇️
gramps/plugins/webreport/basepage.py 55.40% <0.00%> (-1.49%) ⬇️
gramps/plugins/webreport/common.py 62.98% <0.00%> (-1.13%) ⬇️
gramps/plugins/webreport/source.py 86.40% <0.00%> (-1.10%) ⬇️
gramps/plugins/webreport/repository.py 17.75% <0.00%> (-0.88%) ⬇️
gramps/plugins/webreport/contact.py 23.21% <0.00%> (-0.86%) ⬇️
gramps/plugins/webreport/download.py 21.12% <0.00%> (-0.62%) ⬇️
... and 27 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c567b9e...e456286. Read the comment docs.

@Nick-Hall
Copy link
Member

When I go into "Edit -> Preferences" I get the following error:

 ... gramps/gen/utils/configmanager.py", line 381, in get
    raise AttributeError("No such config setting name: '%s.%s'" %
AttributeError: No such config setting name: 'preferences.calendar-format-input'

Were these changes the ones discussed on the Discourse forum thread?

From what I can see in the images in the feature request, the bold headings need to be left justified to conform to our UI Style guide. In particular, the Gnome Human Interface Guidelines section.

@DaveSch-gramps
Copy link
Contributor Author

The only new config setting added was one for @SNoiraud #1161 where he adds register('preferences.calendar-format-input', 0) to gen\config.py now accessed by my gui\configue.py.

All other changes were all only a shuffling of the existing options. A few descriptions alterations are proposed.

In the existing Preferences, the major headings are all center justified. You want them Left justified?

@Nick-Hall
Copy link
Member

You want them Left justified?

Yes. Have a look at the Gnome editor preferences as an example:

gedit_preferences

The indents are multiples of 6 pixels.

@DaveSch-gramps
Copy link
Contributor Author

@Nick-Hall

I have reformatted the tabs with left-justified headers and indented selectors. All tabs were been modified so that they all share the theme with the exception of Colors where I left the tab's header centered. This better reflects having the "Dark" and "Restore" buttons centered directly below. I also made no changes to the Symbols tab.

In reviewing UI Style guide and GNOME Human Interface Guidelines they strongly recommend right-justified labels on the Drop-down and Box options. I have made this change in the current version. Modifying BasicLabel also affected the Relationships and Combined views negatively. The only other file that takes advantage of BasicLabel is _sidebarfilter.py

I created a RightLabel class in gui\widgets\labels.py and used it in gui\configure.py to make labels right-justified.

The problem is an inconsistency in labels. Most notably the Report and Tool/Gramplets configure windows remain left-justified. As they do not use the BasicLabel code any reworking of the code to make them right-justified would be a lot of work and beyond my coding talents.

Notably, the settings in all the filter rules are all right justified.

So the question: Keep the right-justified labels or revert to left-justified?

@DaveSch-gramps
Copy link
Contributor Author

data
general
addons
famtree
import
idformats
limits
researcher
text
warnings

@codecov-commenter
Copy link

Codecov Report

Merging #1149 (e456286) into master (c567b9e) will decrease coverage by 0.12%.
The diff coverage is 0.00%.

❗ Current head e456286 differs from pull request most recent head 2ae0ebc. Consider uploading reports for the commit 2ae0ebc to get more accurate results
Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1149      +/-   ##
==========================================
- Coverage   41.28%   41.16%   -0.13%     
==========================================
  Files        1060     1062       +2     
  Lines      143397   144645    +1248     
==========================================
+ Hits        59204    59538     +334     
- Misses      84193    85107     +914     
Impacted Files Coverage Δ
gramps/gui/configure.py 0.00% <0.00%> (ø)
gramps/plugins/webreport/narrativeweb.py 74.43% <0.00%> (-2.69%) ⬇️
gramps/plugins/webreport/place.py 68.57% <0.00%> (-2.62%) ⬇️
gramps/gen/utils/image.py 14.85% <0.00%> (-1.64%) ⬇️
gramps/plugins/webreport/basepage.py 55.40% <0.00%> (-1.49%) ⬇️
gramps/plugins/webreport/common.py 62.98% <0.00%> (-1.13%) ⬇️
gramps/plugins/webreport/source.py 86.40% <0.00%> (-1.10%) ⬇️
gramps/plugins/webreport/repository.py 17.75% <0.00%> (-0.88%) ⬇️
gramps/plugins/webreport/contact.py 23.21% <0.00%> (-0.86%) ⬇️
gramps/plugins/webreport/download.py 21.12% <0.00%> (-0.62%) ⬇️
... and 27 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c567b9e...2ae0ebc. Read the comment docs.

Clean up of existing Preferences tabs.

Implements #12049
@Nick-Hall
Copy link
Member

So the question: Keep the right-justified labels or revert to left-justified?

I've reverted to left-justified labels, and made a few other minor adjustments. The title in the colour tab is now left justified.

@Nick-Hall Nick-Hall merged commit 677d09e into gramps-project:master Feb 15, 2022
@DaveSch-gramps
Copy link
Contributor Author

Looks great. Thank you for merging.

@prculley 's Theme Gramplet _panel structure must now agree with the changes made here.

Fix already filed

gramps-project/addons-source#472

@Nick-Hall Nick-Hall changed the title Update configure.py Update Preferences dialog Feb 15, 2022
@DaveSch-gramps DaveSch-gramps deleted the update-Preferences branch February 21, 2022 11:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants