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

Way to remove the title bar #48

Closed
sumit-codebrewer opened this issue Mar 2, 2024 · 9 comments
Closed

Way to remove the title bar #48

sumit-codebrewer opened this issue Mar 2, 2024 · 9 comments
Labels
enhancement New feature or request

Comments

@sumit-codebrewer
Copy link

sumit-codebrewer commented Mar 2, 2024

Thankyou for supporting me in my last issue.

I have been trying to remove the title bar from my window by setting WindowStyle ="None" which ideally works for any wpf window. After integrating inkore modern wpf library, it is giving a default title bar at the top. And if I set its height to 0, my buttons will superimpose the bar and stops working.
What is showing
image

What I want
image

Any ideas, how to remove this?

@NotYoojun
Copy link
Member

@sumit-codebrewer
Copy link
Author

Here is the output of that, already tried it earlier

image

The button is overlapping with the title bar and hence, again it will not work.

@biocross
Copy link

biocross commented Mar 7, 2024

Is there a way to remove the close / minimise / maximise buttons?

@NotYoojun
Copy link
Member

This might be a little difficult. Maybe you can use WindowStyle=None and UseModernWindowStyle=false to disable the default frames.

Or I can add some more attached properties for everyone to control the states of the control button. However, I'm afraid this has to be on a few months later cause I'm really busy these days doing web development.

@NotYoojun NotYoojun added the enhancement New feature or request label Mar 29, 2024
@NotYoojun
Copy link
Member

Hi there, We have add some properties to fully customize your title bar buttons.
However, I'm afraid you have to wait a moment before you can use this feature in the nuget package.
You can compile your own by cloning the latest source code (I have pushed the commits).
Also I have made an example for customizing window styles.

image

Here's a sample you can use in the latest version in the future:

<Window x:Class="WindowExample.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        xmlns:ui="http://schemas.inkore.net/lib/ui/wpf/modern"
        xmlns:local="clr-namespace:WindowExample" xmlns:sys="clr-namespace:System;assembly=netstandard"
        mc:Ignorable="d"
        ui:WindowHelper.UseModernWindowStyle="True" ui:TitleBar.Height="36"
        ui:TitleBar.ButtonCloseAvailability="Disabled"
        ui:TitleBar.ButtonMaximizeAvailability="Collapsed"
        ui:TitleBar.ButtonMinimizeAvailability="Auto"
        FontSize="14"
        Title="MainWindow" Height="540" Width="800">
    <Grid>
    </Grid>
</Window>

Also, I will notify you when this feature releases.

@biocross
Copy link

biocross commented Apr 7, 2024

Thank you so much! Will wait for the release 🙏

@NotYoojun
Copy link
Member

Hi there, I have published the release, pls check out!
If you have any questions, feel free to reopen this or create a new issue.

@xmaxrayx
Copy link

xmaxrayx commented Oct 6, 2024

idk is it actually window non style? I tired put <border> inside that titles bar template project and couldn't see it because of binding thing ig .

I tired put everything collapse but seems still there a title bar? because I could do drag.move on top window,

I want something like ALt-tab window you can stick any GUI-CTRL at x0
image

@NotYoojun
Copy link
Member

@xmaxrayx

Maybe ui:TitleBar.Height=0 will help.
Btw when window style is none, all the animations and backdrops will be lost. So this can't be a solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants