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

Title bar icons are too small #1

Closed
bats64mgutsi opened this issue Dec 1, 2020 · 4 comments
Closed

Title bar icons are too small #1

bats64mgutsi opened this issue Dec 1, 2020 · 4 comments

Comments

@bats64mgutsi
Copy link

Hi @bitsdojo, really nice package you have here. However, the minimize, maximize, and close buttons are too small on my PC. They are much smaller than those of the other windows. I'm certain I am not doing anything wrong that might mess with the size, but please help me out if I am.

I took a look at getTitleBarButtonSize() in window_caption.dart and noticed it uses the device-dependent pixel values returned by GetSystemMetrics(int). Shouldn't these be converted to logical pixels?

This is the code I used to render my title bar

class WindowTitleBarView extends StatelessWidget {
  final Widget body;
  WindowTitleBarView({this.body, Key key}) : super(key: key);
  @override
  Widget build(BuildContext context) {
    return Container(
      color: appColors.kcSweetsAppBarColor,
      child: Column(
        children: [
          WindowTitleBarBox(
            child: Row(
              children: [
                Expanded(child: MoveWindow()),
                Row(
                  children: [
                    MinimizeWindowButton(colors: _windowButtonColors),
                    MaximizeWindowButton(colors: _windowButtonColors),
                    CloseWindowButton(colors: _windowCloseButtonColors),
                  ],
                )
              ],
            ),
          ),
          Expanded(child: body),
        ],
      ),
    );
  }
}

And this is how small the buttons look in my window:
image

@technolion
Copy link
Contributor

I can also reproduce this on Windows 10 with a screen resolution of 3440 x 1440:
title-icons-too-small

@bitsdojo
Copy link
Owner

bitsdojo commented Dec 3, 2020

Just pushed 0.0.3. Could you please try it and let me know how it goes?

@technolion
Copy link
Contributor

technolion commented Dec 3, 2020

Yeah, looks great now!

Bildschirmfoto 2020-12-03 um 17 20 29

@bitsdojo
Copy link
Owner

bitsdojo commented Dec 3, 2020

Great! Thanks!

Fixed by 4122e5b

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

No branches or pull requests

3 participants