Adjust individual row height at runtime depending upon the text in the TABLEFIELD

25 views
Skip to first unread message

Jemo

unread,
May 22, 2012, 5:36:34 AM5/22/12
to OpenROAD Users Mailing List
Hello Everyone

Is it possible to adjust the row height at runtime depending upon the
data within a tablefield column(s)?

Suppose a tablefield has a single column and multiple rows
(EntryField), each row has different amount of text, say a range from
10 characters to 2000 characters. I basically want it to auto adjust
and take only required height to display the full text.

Is there any property I need to set to make this automatically
happen(I can't remember) or do I have to handle this manually?

If manually, what is best approach to be followed? Has anyone done
something similar?

Regards,
Jemo

Bodo Bergmann

unread,
May 22, 2012, 6:39:14 AM5/22/12
to openroa...@googlegroups.com
Hi Jemo,

There is no property to automatically adjust the height of the individual cells of a column.
You have to do it manually.
In addition you can't set CharsPerLine and Lines attribute for individual cells,
as these are not CellAttribute attributes.
The only way to change the height for individual cells would be to use different font attributes,
i.e. TypeFace and TypeSize.

HTH.

Regards,
Bodo.

Bodo Bergmann | Sr. Software Engineer | OpenROAD Worldwide Development | Actian
--
You received this message because you are subscribed to the Google Groups "OpenROAD Users Mailing List" group.
To post to this group, send email to openroa...@googlegroups.com.
To unsubscribe from this group, send email to openroad-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/openroad-users?hl=en.

Adrian Williamson

unread,
May 22, 2012, 6:58:13 AM5/22/12
to openroa...@googlegroups.com
Hi,

I suppose you could manually adjust the protofield for the columnfield to
give you the text box size you need to fit the largest piece of text
supplied.

But as Bobo pointed out this would affect all the 'cells' in the column
field.

So if you had two lines of text in one row, and fifty in another row then
all the 'cells' would end up with fifty lines.

I suspect your time would then be spent on window resizing...

Adrian
-----
No virus found in this message.
Checked by AVG - www.avg.com
Version: 2012.0.2176 / Virus Database: 2425/5013 - Release Date: 05/21/12

Peter van Bennekom

unread,
May 22, 2012, 8:14:55 AM5/22/12
to openroa...@googlegroups.com
Hi,

I have never tried this but try to enclose an entryfield inside a stackfield and make that your column - maybe then you can set the entryfield properties per visible row - since this is not a cell you will adjust your entryfields that are visible - not sure if that works...

Cheers,
Peter

Peter van Bennekom | Senior Principal Architect | | office: 610 407 8113 | fax: 610 407 8181 | peter.va...@infor.com

Adrian Williamson

unread,
May 22, 2012, 8:49:58 AM5/22/12
to openroa...@googlegroups.com
Hi,

I'm not sure that would be supported.

The temptation to loot the stuff under the tablebody attribute is almost
irresistible.

But if it works and you don't get caught...

Paul White

unread,
May 22, 2012, 7:03:12 PM5/22/12
to openroa...@googlegroups.com
Hi Jemo,

Could you achieve the desired functionality by managing an array of
entryfields, embedded in stackfields and a viewport?


There have some discussions recently about enhancing functionality of
tablefields. It seems that most developers would like to have more control
over formatting and attributes at the individual cell level.

I like the fact that tablefields are simple and fast - displaying rows of
"identical" data, sorting and searching, copying to and from arrayobjects,
copying to clipboard, resizing and reformatting columns and headers. I'd
want to make sure that enhancements did not detract from the performance of
tablefields.

I wonder, is it time to consider a new type of grid object?

Paul
Reply all
Reply to author
Forward
0 new messages