0

How to align listgroup labels on the left using markup

asked 2009-04-29 09:30:47 +0800

cvarona gravatar image cvarona
554 1 6

updated 2009-04-29 09:31:53 +0800

Hi there,

I've been trying to create listgroups using markup, like this:

<window title="Listbox" border="normal">
<vbox width="100%">
	<listbox rows="1" mold="select">
		<listitem label="Inbox"/>
		<listitem label="Received"/>
		<listitem label="Draft"/>
	</listbox>		

	<separator bar="true"/>
	<listbox fixedLayout="true">
		<listhead sizable="true">
			<listheader align="center" width="40px"
				image="/img/Centigrade-Widget-Icons/ArrowsUpDown-16x16.png" />
			<listheader align="center" width="40px" image="/img/Centigrade-Widget-Icons/Envelope-16x16.png" />
			<listheader align="center" width="40px"
				image="/img/Centigrade-Widget-Icons/PaperClip-16x16.png" />
			<listheader label="Subject" sort="auto"/>
			<listheader label="Received" sort="auto"/>
		</listhead><listgroup>
                    <listcell label="Some group label"  />
</listgroup>
		<listitem height="28px">
			<listcell image="/img/Centigrade-Widget-Icons/ArrowUpOrange-16x16.png" />
			<listcell image="/img/Centigrade-Widget-Icons/EnvelopeOpen-16x16.png" />
			<listcell image="/img/Centigrade-Widget-Icons/PaperClip-16x16.png" />
			<listcell label="ZK Jet 0.8.0 is released" />
			<listcell label="2008/11/17 17:41:29" />
		</listitem>
		<listitem height="28px">
			<listcell image="/img/Centigrade-Widget-Icons/ArrowDown-16x16.png" />
			<listcell image="/img/Centigrade-Widget-Icons/Envelope-16x16.png" />
			<listcell image="/img/Centigrade-Widget-Icons/PaperClip-16x16.png" />
			<listcell label="URLs for iPhone-Optimized Google Sites" />
			<listcell label="2008/11/17 15:56:37" />
		</listitem>
		<listitem height="28px">
			<listcell label=" " />
			<listcell image="/img/Centigrade-Widget-Icons/EnvelopeOpen-16x16.png" />
			<listcell label=" " />
			<listcell label="Style Guide for ZK 3.5 released" />
			<listcell label="2008/11/14 13:23:07" />
		</listitem>
		<listitem height="28px">
			<listcell image="/img/Centigrade-Widget-Icons/ArrowUpOrange-16x16.png" />
			<listcell image="/img/Centigrade-Widget-Icons/EnvelopeOpen-16x16.png" />
			<listcell label=" " />
			<listcell label="ZK Studio 0.9.0 released." />
			<listcell label="2008/11/16 10:26:37" />
		</listitem>
	</listbox>
</vbox>
</window>
Everything right, but the listgroup label appears as centered. I've been unable to find out how to set it up on the left, even if the listbox component's default listitem renderer does it nicely without further specifying anything.

Any ideas?

With kind regards

César Varona

delete flag offensive retag edit

2 Replies

Sort by » oldest newest

answered 2009-04-29 10:14:21 +0800

terrytornado gravatar image terrytornado flag of Germany
9393 3 7 16
http://www.oxitec.de/

updated 2009-04-29 10:15:27 +0800

Hi,

have a try with setStyle.

in java code :

ListCell.setStyle("text-align: left");


Stephan

link publish delete flag offensive edit

answered 2009-04-29 15:10:24 +0800

cvarona gravatar image cvarona
554 1 6

It works! It was the first thing I tried but on the <listgroup> rather than on the listcell. Thanks a lot.

With kind regards

César Varona

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow

RSS

Stats

Asked: 2009-04-29 09:30:47 +0800

Seen: 319 times

Last updated: Apr 29 '09

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More