-
Notifications
You must be signed in to change notification settings - Fork 563
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
native: Implement keyboard focus support in Tab widget #1173
Conversation
This is how Qt apps behave on my linux system. I assume this is actually different on other platforms. |
} | ||
|
||
fs := FocusScope { | ||
key-pressed(event) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No handling for activation?
Apart from this, is there any difference between this TabBarImpl and the one in the fluent style?
Should the 8px spacing come from the native style metrics?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apart from this, is there any difference between this TabBarImpl and the one in the fluent style?
It seems not. So this could be moved in the common/common.slint and re-exported
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But the spacing is indeed suspicious.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I used Krita as an example app and that just switches between tabs as you move with the arrow keys between the different tabs.
The style krita is using by default is pretty horrible. The difference between focused tab-bar and unfocused tab-bar is basically non-existent:-/ But now that I went and looked for it: It does exist, so I need to fix that.
Don't you need to set the focus flags in the QStyle? |
I think the CI issue will be fix by #1180 because it registers all enums. |
@@ -634,6 +634,10 @@ export global NativeStyleMetrics := { | |||
property <color> placeholder-color : native_output; | |||
property <color> placeholder-color-disabled : native_output; | |||
|
|||
// Tab Bar metrics: | |||
property <length> tab-bar-spacing : native_output; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the tab-bar-spacing is not used
Focus the tabs straight away when pressing cursor left/right keys.