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

Ribbon Window's Icon Not Centered #804

Closed
kalatchev opened this issue May 19, 2020 · 4 comments
Closed

Ribbon Window's Icon Not Centered #804

kalatchev opened this issue May 19, 2020 · 4 comments
Assignees
Milestone

Comments

@kalatchev
Copy link
Contributor

When custom height is set, icon is not vertically centered.

I found, that when I use custom height of a window title, icon is is not vertically centered (as on screenshot bellow). Here is my code:

<Fluent:RibbonWindow x:Class="WindowLanguage"
        ... 
        xmlns:Fluent="urn:fluent-ribbon"
        Title="Language"
        TitleBackground="{DynamicResource PrimaryBrush}" TitleForeground="White"
        TitleBarHeight="25"
        ResizeMode="NoResize"
        ShowInTaskbar="False"
        WindowStartupLocation="CenterScreen" 
        Background="White" 
        Icon="pack://application:,,,/iLabCourier;component/Images/iLabCourier.ico">

...

</Fluent:RibbonWindow>

image


Environment

  • Fluent.Ribbon v7.1.0
  • Windows 10
  • .NET Framework 8.8
@batzen
Copy link
Member

batzen commented May 28, 2020

That's intentional.
I changed this back and forth a few times in the past.
Will add a new property or some other way to enable everyone to control this from the outside.

@batzen batzen self-assigned this May 28, 2020
@batzen batzen added this to the 8.0.0 milestone May 28, 2020
@kalatchev
Copy link
Contributor Author

Thanks @batzen .
In cuurent version, what is best way to center?

@batzen batzen closed this as completed in 3551910 Jun 12, 2020
@batzen
Copy link
Member

batzen commented Jun 12, 2020

In the current version the best way would be to somehow get PART_Icon from the template of RibbonWindow and modify the VerticalAlignment.

@kalatchev
Copy link
Contributor Author

Thanks for info @batzen

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants