How to properly display a focus rectangle in a compact SplitView menu item - windows-10

I'm building my first Universal Windows Platform (UWP) App and am trying to implement the popular "Hamburger Menu" using the SplitView class.
Inspired by many samples, the items hosted on the SplitView pane are re-styled RadioButton controls, with a vertical highlight-rectangle, an icon and a text. The appearance is similar to that of the Groove app.
I'm now trying to implement navigation and selection using the keyboard, and this now bring a little focus-rect around the items in the SplitView pane. However, since the pane clips its contents when its DisplayMode is either CompactInline or CompactOverlay, the focus rectangle is also clipped, which is not the behavior a user would expect.
Please, can anyone advise on how to property display the focus rectangle in this situation ?

Just an idea, what if you set the width of all radio button's to be same as the CompactPaneLength property of SplitView. The default is 48 DIPs.

Related

Adding a new component to Unite UX

I'm trying to learn Kendo Unite UX. The design handed over from figma includes an input box with an icon in it. Specifically a design for Hover with an error Icon. There is also a hover with no icon (Which matches to the Hover Component).
I am trying to figure out how I can extend the component set - that is the second image above.

Expanding button to autosuggestbox in UWP

I am trying to configure a button within my UWP app to expand in to an AutoSuggestBox on click. This behavior is mentioned in this post:
https://msdn.microsoft.com/en-us/windows/uwp/controls-and-patterns/search#Implementation
I tried utilizing a flyout on the button click, but it doesn't give me the desired effect. Is there an existing control that can do this or will I need to roll my own XAML of an existing control?
The behavior you see in the blogpost can be easily achieved by having an autosuggestbox hidden behind the button, then after on button click fading out the button and resizing the autosuggestbox to the desired width.
There's no way to "expand" a control into a different one, but you can make it look like that happens :)

Toolbar UI Login - Inbox by Gmail App

I'm looking at different variations of login screens which have material design elements.
I found the Inbox app quite interesting.
The toolbar (action bar) appears to be mid screen. And the (action bar) snaps up to the right position when editing text.
Questions:
Is this a standard behaviour across 5.0?
How do they achieve this?
The UI element you are seeing on the top, playing the role of an ActionBar is actually the Toolbar widget.
A Toolbar is a generalization of action bars for use within application layouts. While an action bar is traditionally part of an Activity's opaque window decor controlled by the framework, a Toolbar may be placed at any arbitrary level of nesting within a view hierarchy. An application may choose to designate a Toolbar as the action bar for an Activity using the setActionBar() method.
You can have multiple toolbars in an Activity. The toolbars can have different heights. The standard height of the toolbar in portrait is 56dp.
Update:
Default height:
Mobile Landscape: 48dp
Mobile Portrait: 56dp
Tablet/Desktop: 64dp
For extended app bars, the height is equal to the default height plus content increment(s).
You can read more from the Material design specification.
For implementing it you just set the layout_height attribute in the layout file. Of course extracting the number as a dimension resource is always a good idea.

Can I use an image instead of a title in an Apple Watch app?

How can I put an icon in the top left label and make fullscreen? Apple allocates some space on top for the digital clock and back label. I would like to customize it, but I can't find anything in the SDK to enable this.
The top strip of the Watch screen is reserved for displaying the page title, or occasionally links such as "Cancel" by default for modal views, and the clock. It is not possible to hide this.
It is possible to set an empty title for a page. Some settings will alsoplace a background image behind this text (if you set the mode to 'Aspect Fill', at least in the current Xcode 6.2 beta 3). However, the portion of the image at the top of the screen is simply occluded by a black strip, so this does not achieve what you want.
Additionally, Apple have specifically recommended against displaying logos on the Apple Watch screen, with the rationale that the screen is too small to display for the user anything but actual content.
To set the Global tint:
Select the Interface Controller itself in Interface Builder by clicking on the Yellow circle at the top of the view of the screen.
Press Cmd-Opt-1 to display the File Inspector section of the Utilites on the right hand side.
Set the 'Global Tint' option in the section 'Interface Builder Document', as per the screenshot.
Not possible in the first cut but I think it will come later.
It's not actually a back label. The text in the top left of the Watch screen is the title of the current WKInterfaceController. You can change it by using -[WKInterfaceTitle setTitle:], but you are limited to content that is expressible in an NSString (so no UIImages).
It is possible to customise the status bar in watchOS 4.
Select your interface controller in the storyboard
Open the attributes inspector
Check the Full Screen checkbox
After doing this you can add your custom image to the left of the statusbar.

How to skin MFC main menu

I got a menu in an existing MFC application that has a standard MFC main menu.
But I would like to change its background colour so that it appears to more seamlessly belong to the rest of the application.
First picture: An MFC main menu. The application is skinned blue, as seen in the toolbar, but the menu is still standard grey background colour.
Second Picture: Spotify's menu, skinned to fit into the rest of the
colors.
I have not found any examples on anything similar. Could you please point me towards how to achieve this?
Approaches I thought of:
Subclassing CMenu to my own SkinnedMenu, but it is not created by our code but by a GetMenu() call in a mainframe class deriving from CFrameWnd. The only thing I can find here is its method signature, defined in afxwin.h so then how could I make use my own subclassed menu?
Removing the entire menu and add my own custom menu buttons, in a row, making it look like a menu. Maybe this is what spotify have done, as they have also removed the Windows window frame.
Editing the existing CMenu in some way, but the only customization I am able to find right now is modifying its MENUINFO. For example if I set info.hbrBack = skin.GetSysColorBrush(COLOR_MENU) the only colour that changes is the background of the dropdown, not the main menu itself.
Other :)

Resources