Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Scout » Swing: Default-Field Height to small?
Swing: Default-Field Height to small? [message #1053345] Sat, 04 May 2013 08:14 Go to next message
Volkert B. is currently offline Volkert B.Friend
Messages: 12
Registered: June 2012
Junior Member
It looks like the default text field height is too small. See the picture. The letters with decender height (j,g,..) have not enough space.

index.php/fa/14636/0/

It there a way to change the default height setting?

BW,
Volkert
---
Eclipse Juno SR2 / Scout 3.8.2
Windows 7 SP1
Java 1.7.0_21

[Updated on: Thu, 09 May 2013 05:08]

Report message to a moderator

Re: Swing: Default-Field Height to small? [message #1053432 is a reply to message #1053345] Sun, 05 May 2013 15:41 Go to previous messageGo to next message
Jeremie Bresson is currently offline Jeremie BressonFriend
Messages: 1252
Registered: October 2011
Senior Member
You use the default Nimbus Swing look and feel?

I remember there is a property or a configuration you can set somewhere... I will try to find it.
Re: Swing: Default-Field Height to small? [message #1053453 is a reply to message #1053432] Mon, 06 May 2013 04:14 Go to previous messageGo to next message
Volkert B. is currently offline Volkert B.Friend
Messages: 12
Registered: June 2012
Junior Member
Jeremie Bresson wrote on Sun, 05 May 2013 17:41
You use the default Nimbus Swing look and feel?


Yes ...
Re: Swing: Default-Field Height to small? [message #1053592 is a reply to message #1053453] Mon, 06 May 2013 16:08 Go to previous messageGo to next message
Jeremie Bresson is currently offline Jeremie BressonFriend
Messages: 1252
Registered: October 2011
Senior Member
Hi,

You can control the height of the fields in a scout form by overriding a method in your swing environment:

<your app>.ui.swing.SwingEnvironment:

public class SwingEnvironment extends org.eclipse.scout.rt.ui.swing.DefaultSwingEnvironment {

  @Override
  public int getFormRowHeight() {
    return 40;
  }
}


index.php/fa/14667/0/

For other properties (font...) you can take control of the LookAndFeel properties (have a look at javax.swing.plaf.basic.BasicLookAndFeel in the Swing code).

Re: Swing: Default-Field Height to small? [message #1057824 is a reply to message #1053592] Thu, 09 May 2013 05:06 Go to previous messageGo to next message
Volkert B. is currently offline Volkert B.Friend
Messages: 12
Registered: June 2012
Junior Member
Thanks.

Is it now possible to have a vertical centered label (aligned to the center of text field)?

index.php/fa/14711/0/
  • Attachment: center.PNG
    (Size: 1.97KB, Downloaded 600 times)

[Updated on: Thu, 09 May 2013 05:07]

Report message to a moderator

Re: Swing: Default-Field Height to small? [message #1059591 is a reply to message #1057824] Mon, 20 May 2013 16:01 Go to previous message
Jeremie Bresson is currently offline Jeremie BressonFriend
Messages: 1252
Registered: October 2011
Senior Member
Hi,

I did not forget you, but it seems to be complicated (I do not know Swing well).

So far, I had a look at:
org.eclipse.scout.rt.ui.swing.AbstractSwingEnvironment.createStatusLabel(IFormField)


I did not manage to understand if the JLabel contained in the JPanel labelPanel of the StatusLabelEx has the correct size or not. Maybe a call like this is missing (in the Constructor of JStatusLabelEx()):
m_label.setVerticalTextPosition(SwingConstants.CENTER)


I will try to figure it out.
Previous Topic:Renaming Services
Next Topic:Eclipse Scout on OS X Java 7
Goto Forum:
  


Current Time: Fri Apr 19 01:51:59 GMT 2024

Powered by FUDForum. Page generated in 0.02983 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top