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

Rework Qgs(Double)SpinBox clear handling #3468

Merged
merged 6 commits into from Sep 8, 2016

Conversation

nyalldawson
Copy link
Collaborator

The current approach used by Qgs(Double)SpinBox of having a child tool button for the clear button has some issues:

  • poor appearance on certain environments (esp OSX)
  • large "dead" area on spin boxes' right which swallows clicks and blocks interactivity

This PR reworks the spin boxes to use QgsFilterLineEdit for handling the drawing and click detection for the clear button.

Here's a before/after on OSX:

screen shot 2016-09-08 at 9 48 07 pm

screen shot 2016-09-08 at 9 54 40 pm

I've always hated seeing screenshots of QGIS on OSX because of this issue...

Now the widget gracefully handles shrinking
and have clearing the widget reset to default rather than
null
Fixes issues with the current approach:
- poor appearance on certain environments (esp OSX)
- large area on spin boxes' right which "swallows" clicks
and blocks interactivity

Fix qgis#12920
@m-kuhn
Copy link
Member

m-kuhn commented Sep 8, 2016

I've always hated seeing screenshots of QGIS on OSX because of this issue...

Agreed. Thanks for tackling this.

@nirvn
Copy link
Contributor

nirvn commented Sep 8, 2016

Oh, getting rid of the dead area is most welcome in the context of narrow style dock too. No more digits cut away by white empty space!

@nyalldawson nyalldawson merged commit f52a9a0 into qgis:master Sep 8, 2016
@nyalldawson
Copy link
Collaborator Author

I'll merge and backport to master_2 for more testing

@nyalldawson nyalldawson deleted the spin_box_v2 branch September 22, 2016 01:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants