as you can see in the picture, Windows 10 mobile is using lots of These bars at the bottom. It has Icons (in the picture: "Mailbox", the "Plus" sign etc.) in it and over it are a few Options ("Einstellungen" etc.)which appear when you click the three points.
But how Looks the General form of them in C#?
I went through the whole Internet but I still canĀ“t find out how you create These bars.
You are looking for a CommandBar class, which is placed in a Page.BottomAppBar, especially check its properties like PrimaryCommands and SecondaryCommands.
You should use a special AppBarButton s inside a CommandBar, whuch are classic Buttons but with a special rendering, to create it you just set the Icon and Label.
Check the guidelines for command bars.
Related
let's say I want to make program settings menu like:
Many tab options that change the layout of the rest of the window
My program is in C# and I'm making it in Visual Studio
I tried to do it 2 ways:
Make the window super large with all possible layouts in the Form designer and then just resizing it to fit one of them at the time but this method works for like 4 tabs when you can fit them all at 1 screen. If it's large you have to work with slide bars and that's really impractical, laggy and for many tabs you even have to search them
Not using Form designer at all and hand write all the declarations, positions, sizes, colors etc. But like this it takes pretty a while even just to set up 1 button and there is no way I can fast see how it looks like
So the question is: Is there a magic way I don't know about to do this? And how is this made professionally?
Simple solution for small number of views
You can use a TextBox and ListView docked in a Panel docked left.
And a ControlTab docked fill in a panel named for example PanelMain docked fill at right with visible at false.
You will create any tabpage as option. In each tabpage you will put a panel docked fill and dedicated content in. On the listview item click event or itemchange, you will set the tabpage panel parent to PanelMain.
The little problem can be about spacing and the code file can be large (regions can be used).
Advanced solution more clean for several views
You can use the standard multipage pattern with one form per option/view, and do the same thing as exposed previously.
You create one form per view and put a panel docked fill embedding controls.
When the user click on the menu, you set the form main panel parent to the option form or the main panel of the options form.
I hope I haven't written too badly in unverified English.
Feel free to open any new question centered on any atomic and code problem on this subject.
How can I make a TitleBar like Groove Music? It has an auto back button with the app name. Additionally, it's NavigationViewPane is extended to the TitleBar.
So I first added:
Windows.ApplicationModel.Core.CoreApplication.GetCurrentView().TitleBar.ExtendViewIntoTitleBar = true;
and then make the back button of NavigationView visible. However, there is a known issue with that. Basically, part of that back button is covered by something which makes it only clickable somewhere. Although a solution is provided here, it doesn't seem to have a good compatibility with the AppViewBackButton (for example I only want the AppViewBackButton to be blue) and I couldn't make it work.
Then I tried using SystemNavigationManager.GetForCurrentView().AppViewBackButton but that button doesn't seem to be same as the Groove Music, because that one aligns well with the buttons in the NavigationView. I could redesign the NavigationViewStyle to make them fit but that requires a lot of work (how do I get the size of AppBackButton or how to customize it?). And the OpenPane of the NavigationView has a shadow but I didn't find it in the original style.
Is there a better way to do it?
UWP Groove Music Title Bar
UWP Groove Music app's back button contains two types, one is NavigateView's BackButton, other is AppViewBackButton.
for example I only want the AppViewBackButton to be blue
You could check the back button of Now Playing page, it is AppViewBackButtonthat the background color follow the system setting. You could custom it by switching other color in the Windows colors setting.
Update
The problem is the button is click able control, if you call SetTitleBar method set the button as title bar, the button will disable.
Please add the following
CoreApplication.GetCurrentView().TitleBar.ExtendViewIntoTitleBar = true;
And remove Window.Current.SetTitleBar(EmptyTitleBar); in NowPlayingFullPage method.
Just turn my comment under NicoZhu's post into an answer.
To create a title bar like Groove music, you need to customize it. And modify your code based on the code here at the bottom.
Additionally, if you need to switch pages, you would better add this to the Page_Loaded event of pages that you will be switching so that your title bars are draggable:
Window.Current.SetTitleBar(AppTitleBar);
Hi I need to show the user a web like UI. Most of the website have three lines in the right bottom corner to show user that the control is expandable.
I need to show the same in the windows form as shown in the picture
Is it possible in winforms to show there lines in the right bottom corner like this in WPF with telerik?
I tried enabling SizrGripStyle to show but it doesn't work in telerik radForm.It only works on winforms
You would have to set the form Property SizeGripStyle to Show in order for the grip lines to be shown. Please refer below.
Once the above property is set to Show the re-size grip would be shown in the on right hand corner of the screen.
I'm on Windows 7 PC, so hope that the re -size grip is distinguishable in the above image.
It seems that currently there is an issue with this functionality: http://feedback.telerik.com/Project/154/Feedback/Details/151535
What you can do is to add an empty RadStatusStrip control and use its sizing grip
I am using an AxWindowsMediaPlayer in a WindowsFormsHost in a WPF application.
I'm having problems with sizing the control.
I need to hide the video part, and keep only the part with buttons and seek bar. (since I run audio)
I need to adjust the WindowsFormsHost to only display this part.
I tried to resize the WindowsFormsHost manually so that it only shows the required part, but when I tested the program on different pc's it wasn't displayed properly. Some parts from the control were cropped.
I know you want to hide the video with the uiMOde
awWindowsMediaPlayer.uiMode= "invisible";
But, this hide controls too...
For me, you have two solutions:
the first, you create your axWindowsPlayer form with 45pixel of height for display just the controls button.
the seconds, you hide all the form, and create all your button...
you've acces at the controls button with : (play button for sample)
axWindowsMediaPlayer.Ctlcontrols.play();
And you've acces to the settings with : (volume for sample)
axWindowsMediaPlayer.settings.volume = 25;
I also saw that it was possible to define a custom uiMode, but I did not find any information about that...
You have two options.
Set uiMode to invisible and define your own buttons (functions are accesable like: axWindowsMediaPlayer.Ctlcontrols.stop();).
Set uiMode to mini or full and set height 40. It leaves control without video visible (link: http://msdn.microsoft.com/en-us/library/windows/desktop/dd562469%28v=vs.85%29.aspx)
You can also hide status, bar and controls
axWindowsMediaPlayer.uiMode= "None";
I would like the same tool tip message (the one entered in the "ToolTip on myControlId" field) to be displayed when the mouse is hovered over an area which contains multiple controls. I tried putting the controls inside a Panel and GroupBox, but it only works when the mouse is in the "white space" area of the Panel/GroupBox, and, of course, does not work when the mouse is on a control within the Panel/GroupBox.
I'm from the web dev world so I'm open to suggestions for a new approach if I'm going about this the wrong way.
In standart windows developmern (WindowsForms) tootltip or tooltip control is associated to a single control. But you can use ToolTip control (see example how: ToolTip: Windows Forms .NET) and assign to all controls that recieve mouseover event.
If you're in WPF, the story becomes easier as you have message routing so usually it's enought to have subscription in one place.
Hope this helps.