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

Project Selector #31

Closed
mottosso opened this issue Jul 9, 2019 · 2 comments
Closed

Project Selector #31

mottosso opened this issue Jul 9, 2019 · 2 comments
Labels

Comments

@mottosso
Copy link
Owner

mottosso commented Jul 9, 2019

Goal

Enhance the project selection experience, and facilitate additional "layers" of projects.

Motivation

image

Projects are rather boring looking right now, and wouldn't scale to also selecting packages for assets or shots.

Implementation

image

@mottosso mottosso added the ui label Jul 9, 2019
@mottosso
Copy link
Owner Author

mottosso commented Jul 9, 2019

Trying the QComboBox.setEditable(True) which enables a default QCompleter. But found that the view associated with the combo box is limited in width to the associated QLineEdit, which is problematic. I also had trouble with the height of the view, which is a QListView, in that it didn't show all items for whatever reason.

Rather than fighting this, I'll separate the responsibilities into (1) a typing mechanism and (2) a selection mechanism. The typing hooks into the selection, by automatically selecting closest-match to what is typed, much like how I would have expected the default mechanism to work.

projectselect

@mottosso
Copy link
Owner Author

mottosso commented Jul 9, 2019

Implemented.

  • Underline and cursor change on hover
  • Keyboard navigation
  • Text select, with auto-completion

Click on project icon, plus type

allzpark_projectselect1

Type and navigate

Double-TAB to re-select project, and continue editing. Arrow keys to switch from list, standard hotkeys like CTRL+A to select all and HOME to move to start of line works as expected.

allzpark_projectselect2

This took far too long, so I'm delaying the tree view and icons till next time.

In order to facilitate this behavior, as an added bonus projects are now fetched up-front, whereas before they were fetched on-demand. I initially thought fetching all versions of a project would be too costly, but have found that it's near instance. The benefit is that we're able to benefit from package metadata for a project in the GUI now, such as an icon (and label). For next time.

mottosso added a commit that referenced this issue Jul 9, 2019
@mottosso mottosso closed this as completed Jul 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant