realbasic-betas.mbox
[Top] [All Lists]

Re: EditField speed trials with 4.5.2fc1 - surprising results

To: REALbasic Betas <realbasic-betas at lists dot realsoftware dot com>
Subject: Re: EditField speed trials with 4.5.2fc1 - surprising results
From: Steve Schacht <shot at frontier dot net>
Date: Mon, 28 Oct 2002 16:38:10 -0700
On 10-28-2002 4:23 PM, Chris K. wrote:

>> P.S.  I have not had time to change my message log window to use a
>> ListBox in place of an EditField.
> 
> I've experimented a bit with this, and it does seem to improve
> performance quite a bit. The only problem I can tell is that it seems
> impossible to wrap the contents of a cell, which is a bit of a drag
> when you don't have direct control over the length of the text you are
> adding (for instance, when it is a user entered value).

Text can be wrapped in a LB if you handle the text drawing yourself in the
CellTextPaint event handler.  Just use the StringHeight method to determine
the height of the row, and use that value to set the DefaultRowHeight.  Two
caveats...  First, every row will of course be as tall as the tallest row.
(It'd be a neat RB feature to be able to set row heights individually.)
The cell contents will even wrap dynamically as the LB width decreases on
reasize.  And secondly, I haven't yet worked out a good clean approach to
"unwrap" text if the LB's width increases.


---
Steve Schacht
shot at frontier dot net


---
A searchable archive of this list is available at:
<http://dbserver.realsoftware.com/KBDB/search.php>

Unsubscribe:
<mailto:realbasic-betas-off at lists dot realsoftware dot com>

Subscribe to the digest:
<mailto:realbasic-betas-digest at lists dot realsoftware dot com>
.


<Prev in Thread] Current Thread [Next in Thread>