View unanswered posts | View active topics It is currently Sun May 28, 2017 7:52 am



Reply to topic  [ 9 posts ] 
 MigLayout_HiDPI 
Author Message

Joined: Wed Jun 10, 2009 5:06 pm
Posts: 3
Post MigLayout_HiDPI
Hello,

I am developing Java GUI desktop application with Swing library and i have requirement to support standard screens and HiDPI screens. Java application
will work on Linux OS. I am interested can i use MigLayout and be sure that
all components will scale well on HiDPI screen, keeping in mind that application needs to run on Linux OS?

Thanks.


Wed Jun 10, 2009 5:20 pm
Profile
Site Admin

Joined: Mon Dec 06, 2004 4:24 pm
Posts: 2485
Location: Sweden
Post Re: MigLayout_HiDPI
Hello,

MigLayout will handle the layout correctly in a HiDPI scenario. However, the Layout Manager is just one part of the equation. The Look&Feel must also scale (fonts, lines etc.). Substance is one that I know works.

But in the end you need to test. Because it is for instance also important that the OS reports the correct DPI to Java.

Cheers,
Mikael


Wed Jun 10, 2009 7:26 pm
Profile WWW

Joined: Wed Jun 10, 2009 5:06 pm
Posts: 3
Post Re: MigLayout_HiDPI
Thanks Mikael,

What about L&Fs that MiG Layout manager supports?
I mean is it possible to combine any L&F which scales well
on HiDPI screens with MiG Layout manager?

-- Because it is for instance also important that the OS reports the correct DPI to Java.

What about Linux OS, do you have any experience does it reports
correct screen DPI? I run HiDPI simulator on Linux Fedora and get
good results with MiG Layout and Substance L&F but i suppose that
i need to test it in real scenarios to be completely safe.


Wed Jun 10, 2009 8:11 pm
Profile
Site Admin

Joined: Mon Dec 06, 2004 4:24 pm
Posts: 2485
Location: Sweden
Post Re: MigLayout_HiDPI
MigLayout supports all L&Fs.

Here is a little article I wrote a while ago, it contains some more info:

http://www.javalobby.org/java/forums/t101878.html

I know that the creator of Substance has written a few articles on the subject as well.

Cheers,
Mikael


Wed Jun 10, 2009 10:42 pm
Profile WWW

Joined: Wed Jun 10, 2009 5:06 pm
Posts: 3
Post Re: MigLayout_HiDPI
Hello Mikael,

What i need to do to set the correct DPI to MiGLayout?
I suppose that i had to get dpi with getScreenResolution() but how to
pass the correct DPI value to MiGLayout?

Thanks.


Thu Jun 11, 2009 1:39 pm
Profile
Site Admin

Joined: Mon Dec 06, 2004 4:24 pm
Posts: 2485
Location: Sweden
Post Re: MigLayout_HiDPI
The gaps should automatically adjust to the current DPI. But you can force it with as well. Check out the PlatformDefaults class.


Thu Jun 11, 2009 1:42 pm
Profile WWW

Joined: Mon Nov 23, 2009 1:28 pm
Posts: 2
Post Re: MigLayout_HiDPI
Hello,
I'm very interesting to see how we must code an indepedent resolution GUI. Can we download the code of your simulator ?


Mon Nov 23, 2009 1:33 pm
Profile
Site Admin

Joined: Mon Dec 06, 2004 4:24 pm
Posts: 2485
Location: Sweden
Post Re: MigLayout_HiDPI
Hello,

It should be in the source code package under examples.

It's really easy though since it's there by default. Though to test you need to explicitly set the DPI, or get a screen with a higher DPI than usual and have the OS understand that.

Cheers,
Mikael


Mon Nov 23, 2009 1:41 pm
Profile WWW

Joined: Mon Nov 23, 2009 1:28 pm
Posts: 2
Post Re: MigLayout_HiDPI
Ok, I'm find it. Thanks.


Mon Nov 23, 2009 2:57 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 9 posts ] 

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.