JavaFX 2 - Autoscroll to last item in exceeded toolbar - css

I am creating File Manager like Miller column app for windows in JavaFX for learning purpose.
Check the screenshot below:
As you can see, when toolbar exceeds, there comes a double arrow button for more items to select from popup.
I already did auto scroll for miller column, which works as expected.
scrollPane.hvalueProperty().bind(hBox.widthProperty());
I would like to auto scroll toolbar to last item and show double arrow on left side.
I am adding adding clickable buttons in toolbar for traversing like manual BreadCumBar.
Tried ControlsFX BreadCumBar, it doesn't even show arrows or popup when exceeds, Bug here : https://bitbucket.org/controlsfx/controlsfx/issues/810/no-double-arrow-popup-like-when.
If its not possible to do so with toolbar, I would like to know how to customize toolbar popup only via css. Or any other way that improve usability easiness.
Also I would love to know suggestions for whole app from expert designers.
Thanks.

Related

a11y in PC Chrome: Up/Down Arrow keys causing yellow highlight when JAWS open

I've been working over the past several months to make a site accessible and a JAWS issue has recently brought to my attention by our QA department.
I've put up a CodePen showing an example similar to what I've built. The main piece here is the Track List:
<div id="track-list"
tabindex="0"
role="menu"
aria-expanded="true"
aria-activedescendant="ch1">
https://codepen.io/Motorcykey/pen/qyJrWX
Background:
The idea is that we have a Chapter list of menu-items which can be hidden or shown by clicking a Button. When the list is showing, you will tab from the Chapters button into the list. Once in the list, Tab & Shift+Tab will only scroll through the menu items. Only the 'Esc' key will exit the list.
The Issue:
Without JAWS running this works fine. If a user attempts to hit the 'Up/Down' keys, nothing out of the ordinary occurs.
However, once JAWS is open it was found that if the Up/Down keys were used then a colored highlight box would appear that would read other parts of the page without necessarily focusing them. Originally, this would include the hidden menu-items, but I was able to get rid of this by setting their display to 'none' (as opposed to just setting their opacity to '0').
However, you can still see in this example that if you take the following steps:
Tab to Chapters Button
Hit Space or Enter to hide the menu
Hit the 'Down' Key on the keyboard. The next, "Play/Pause button" should highlight and be read aloud by JAWS screen reader.
Meanwhile, the 'Chapters' button remains 'focused' with the default browser highlight.
My question is around this highlight box and the expected function of Up/Down keys within JAWS. What is the purpose of this highlight box as it seems decoupled from the browser focus. Is there a way to disable it? Do users typically use Up/Down keys, and if so, does this look like the expected behavior or should I be taking more into consideration to avoid confusion around these keys while working on accessibility updates?
Thank you,
-Mikey
an element with role="menu" must be controlled by arrow keys e.g. down arrow key moves focus to the next menu item and up arrow moves to the previous menu item and tab/shift+tab must moves focus to the next/previous page element. the correct implementation example: https://www.w3.org/TR/wai-aria-practices-1.1/#menubutton

qml: achieve a chrome-like menu

I would like to achieve with QML a menu with a single menu item, like chrome does it. It has this button with those three horizontal bars and when you click it you get a single menu. Recent versions of firefox also follow the same principle. It allows not to waste too much horizontal space in the GUI of the application, unline usual menus which take up the whole width of the window.
I did not manage to reproduce exactly this GUI with QML. From what I saw you can either use a QML ApplicationWindow, and then a MenuBar, but then it takes the whole width of the window... Or have a toggle button to trigger the menu, then use a standalone Menu and its popup() method, but then it pops-up directly under the cursor, not exactly under the button to open the menu, which doesn't look good. That's really more abusing the mechanism for a context menu.
I could make a fake menu which would be a custom widget in my window but then it could not expand beyond my application window. Such a behaviour is almost required because I'll put this button on the far right of the window, as chrome does it.
Is it possible to achieve exactly that behaviour in pure QML (no C++)?
What I did for now is the last option that I mentioned: fake menu in the window. It's drawing using the canvas which enables me to make it a little pointy arrow from the menu to the menu toggle button, as done also by firefox.
The minus as I said is that the menu cannot go out of the window, plus everything is very manual (mouseover effect for menu items...), so I'm still interested in other solutions.
EDIT: ok after some time I realized a big plus of my approach: I can put custom widgets, not only labels in the menu. So I think it's absolutely the right approach now.

How to change QIcon color?

I am working on a custom control box (that min,max/restore/close button in the top right of your Windows titlebar) for my new application. I use closeIcon = style.standardIcon(QStyle.SP_TitleBarCloseButton) to get the correct icon for them. See the full code here in my other SO question. What I got is a black icon. In which I need the white version when it's in hover state.
Can we .. I don't know, inverse it? Or should I get another icon from QStyle?
This question (and several others) are from the intention of creating a chrome like tab in PyQt application, by hiding the titlebar and reimplementing control box. But it didn't gives the best result. Right now this is my solution to create a chrome like tab in PyQt application. Therefore, I close this question.

iPad SplitView Master View shows but with minor (and incorrect) variation

I'm practicing development of a simple iPad Split View app (Stanford's Hegarty online class). And everything works for the most part. However, the Master side ('left side), although working in landscape mode looks a little different than what I expect it to as a 'popover' in portrait mode. The 'popover' covers the left side of the screen including the toolbar button item that triggered it where normally it should not cover that button.
Unfortunately I can't post images so I'll try my best to describe in more detail. Normally the 'proper' popover will be hovering right below the bar item button that triggered it with a thick arrow-ish thingie (the 'anchor') pointing to the button and not covering that button. The popover can be dismissed by clicking on that button again (or elsewhere on the screen).
What's happening to me, however, is that when I click the bar item button to show the popover, the resulting popover 'covers' the button and essentially fills up the left portion of the screen (the detail view is under it and most of it is showing) with its designated width (so, again, it doesn't cover the entire detail view). The is no 'anchor' arrow pointing to the bar item button since it is obviously covering it instead. The popover is dismissed normally once I click anywhere else on the screen.
So why is my popover covering the button and not simply hovering under it with an 'anchor' pointing to it as it should?
I don't think it it makes much sense to post code at this point because I don't think it'll help and more importantly not sure what portion to post considering this might be a problem with how I wired it in the Builder. Any thoughts will be greatly appreciated!
Thanks!
Mo
I believe its a change that came in IOS5.1
If you want the same behaviour you probably need to set the master up as a popover segue, from a toolbar button or similar in the detail view, and set the split view delegate to not show the master in portrait.
I'm on the move now but if you want any more info let me know and I'll try and get back to you later.

Animated auto-hide ApplicationControlBar

Anyone know how to create animated auto-hide on ApplicationControlBar just like Windows's taskbar?
I'm totally new on this.
Thanks.
The issue with doing this is that on Windows, you have a 'lower bound'--also known as the bottom of the screen which is used to trigger the display of the task bar based on the mouse location.
In a browser based app, you don't have that spot which is easy for the user to roll their mouse over.
That said, if you're still adamant, you should be able to put something together easily using the mouse over events to swap the visibility of the ApplicationControlBar and then you can use show / hide effects to display the control bar.

Resources