Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Software must support the user's settings for font size but how itworks with swing?

Reply
Thread Tools

Software must support the user's settings for font size but how itworks with swing?

 
 
Markus Lemcke
Guest
Posts: n/a
 
      04-27-2013
I make a java software accessible. One rule ist the following:

1. Software must support the user's settings for font, size and color. Software that provides
custom application settings for font, size and color must provide the user an option to choose
the systems settings for displayed information rather than using the custom application settings
provided by the software.

What I must code in Java with swing, that my software display the system font size?

Greetings


Markus Lemcke
http://www.marlem-software.de/marlemblog/
 
Reply With Quote
 
 
 
 
Stanimir Stamenkov
Guest
Posts: n/a
 
      04-27-2013
Sat, 27 Apr 2013 14:00:42 -0700 (PDT), /Markus Lemcke/:

> I make a java software accessible. One rule ist the following:
>
> 1. Software must support the user's settings for font, size and color. Software that provides
> custom application settings for font, size and color must provide the user an option to choose
> the systems settings for displayed information rather than using the custom application settings
> provided by the software.
>
> What I must code in Java with swing, that my software display the system font size?


May be your best bet is to use the SystemLookAndFeel:

http://docs.oracle.com/javase/tutori...feel/plaf.html

UIManager.setLookAndFeel(UIManager.getSystemLookAn dFeelClassName());

In practice, at least on Windows it doesn't use the user configured
"caption" and "message" fonts for most components like lists, trees
and tables (like Windows Explorer does, for example), but just the
fixed Windows "system font" which only changes in size depending on
the system DPI setting.

--
Stanimir
 
Reply With Quote
 
 
 
 
Stanimir Stamenkov
Guest
Posts: n/a
 
      04-27-2013
Sun, 28 Apr 2013 01:25:16 +0300, /Stanimir Stamenkov/:

> UIManager.setLookAndFeel(UIManager.getSystemLookAn dFeelClassName());
>
> In practice, at least on Windows it doesn't get the user configured
> "caption" and "message" fonts for most components like lists, trees
> and tables (like Windows Explorer does, for example), but just the
> fixed Windows "system font" which only changes in size depending on
> the system DPI setting.


I remember previously hacking the Windows L&F for that purpose by
reading the corresponding desktop property:

http://docs.oracle.com/javase/6/docs...w2k_props.html

--
Stanimir
 
Reply With Quote
 
Jeff Higgins
Guest
Posts: n/a
 
      04-27-2013
On 04/27/2013 05:00 PM, Markus Lemcke wrote:
> I make a java software accessible.


Again, I would suggest a more specialized forum.

https://forums.oracle.com/forums/forum.jspa?forumID=952

 
Reply With Quote
 
Stanimir Stamenkov
Guest
Posts: n/a
 
      04-27-2013
Sat, 27 Apr 2013 19:14:53 -0400, /Jeff Higgins/:
> On 04/27/2013 05:00 PM, Markus Lemcke wrote:
>
>> I make a java software accessible.
>> [...]
>> What I must code in Java with swing, that my software display the system font size?

>
> Again, I would suggest a more specialized forum.
>
> https://forums.oracle.com/forums/forum.jspa?forumID=952


I guess "comp.lang.java.gui" should be appropriate, too?

--
Stanimir
 
Reply With Quote
 
Jeff Higgins
Guest
Posts: n/a
 
      04-27-2013
On 04/27/2013 07:19 PM, Stanimir Stamenkov wrote:
> Sat, 27 Apr 2013 19:14:53 -0400, /Jeff Higgins/:
>> On 04/27/2013 05:00 PM, Markus Lemcke wrote:
>>
>>> I make a java software accessible.
>>> [...]
>>> What I must code in Java with swing, that my software display the
>>> system font size?

>>
>> Again, I would suggest a more specialized forum.
>>
>> https://forums.oracle.com/forums/forum.jspa?forumID=952

>
> I guess "comp.lang.java.gui" should be appropriate, too?
>

As far as topic. The Oracle Accessibility forum is
more focused and a much higher volume. ^Shrug.


 
Reply With Quote
 
Roedy Green
Guest
Posts: n/a
 
      05-01-2013
On Sat, 27 Apr 2013 14:00:42 -0700 (PDT), Markus Lemcke
<(E-Mail Removed)> wrote, quoted or indirectly quoted
someone who said :

>What I must code in Java with swing, that my software display the system font size?


have a look at http://mindprod.com/applet/fontshower.html
It is an app for displaying sample fonts in various colours and sizes.
--
Roedy Green Canadian Mind Products http://mindprod.com
Nothing is so good as it seems beforehand.
~ George Eliot (born: 1819-11-22 died: 1880-12-22 at age: 61) (Mary Ann Evans)
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Windows 8 - so bad it's hastening the death of the PC? ~misfit~ NZ Computing 18 04-15-2013 04:15 AM
How to install/uninstall manpages with distutils/setuptools? Santosh Kumar Python 0 04-13-2013 08:25 PM
How to move text within Jlabels to the right clusardi2k@aol.com Java 6 04-13-2013 07:20 PM
How to Integrate STRUTS1.3 with crystal report Laxmidhar Sahoo Java 0 04-13-2013 09:31 AM



Advertisments