Field bug ? (was Re: Pairs in fields...)
[1/5] from: carl::cybercraft::co::nz at: 15-Oct-2002 10:09
Hi Anton,
Thanks - I remember seeing it now. And it's showed me that the
problem I was having had nothing to do with my script - as it's in
yours too. The problem's with field itself. Enter the following at
the console...
test-lo: layout [
field "aaa" 60
field "bbb" 60
]
view/offset layout [
button "Test" [view/new test-lo]
] 20x200
click on the "Test" button and then add some text to the first field
untill it scrolls the "aaa" out of view. Then, without pressing
Enter, close the window and click on the "Test" button to open it
again. After I do that the "bbb" in the second field is no longer
visable. This is with...
>> about
REBOL/View 1.2.1.1.1 21-Jun-2001
Is it the same with the new beta Views?
Carl.
On 15-Oct-02, Anton wrote:
> Yes, my pair edit doesn't use the control key
> though, it just uses double-click and single-click
<<quoted lines omitted: 23>>
>> --
>> Carl Read
--
Carl Read
[2/5] from: g:santilli:tiscalinet:it at: 15-Oct-2002 0:43
Hi Carl,
On Tuesday, October 15, 2002, 12:09:35 AM, you wrote:
CR> test-lo: layout [
CR> field "aaa" 60
CR> field "bbb" 60
CR> ]
You can fix it with:
test-lo: layout [
field "aaa" 60 para []
field "bbb" 60 para []
]
To have it fixed globally you could do something like:
stylize/master [
Field: Field with [
append init [
para: make para []
]
]
]
Regards,
Gabriele.
--
Gabriele Santilli <[g--santilli--tiscalinet--it]> -- REBOL Programmer
Amigan -- AGI L'Aquila -- REB: http://web.tiscali.it/rebol/index.r
[3/5] from: carl:cybercraft at: 15-Oct-2002 20:40
Ahah! Thanks Gabriele! Any idea why this fixes it? I notice just one
para [] in any field is enough to cure the problem. ie this fixes
it...
test-lo: layout [
field "aaa" 60
field "bbb" 60 para []
]
view/offset layout [
button "Test" [view/new test-lo]
] 20x200
Nice to know there's such a simple workaround, anyway.
Carl.
On 15-Oct-02, Gabriele Santilli wrote:
> Hi Carl,
> On Tuesday, October 15, 2002, 12:09:35 AM, you wrote:
<<quoted lines omitted: 17>>
> Regards,
> Gabriele.
--
Carl Read
[4/5] from: g:santilli:tiscalinet:it at: 15-Oct-2002 11:37
Hi Carl,
On Tuesday, October 15, 2002, 10:40:46 AM, you wrote:
CR> Ahah! Thanks Gabriele! Any idea why this fixes it? I notice just one
CR> para [] in any field is enough to cure the problem. ie this fixes
CR> it...
That's because they're just two. If you have more, you'll need at
least n-1 of them (also counting fields in other windows).
That is because the amount of text scrolling is in
FACE/PARA/SCROLL; as long as the FACE/PARA object is shared among
all fields, as it is by default, you get that effect. You need to
clone it for every field to avoid that.
BTW, my global fix example should also set the para flag in the
face, so that a subsequent SET-PARA doesn't need to clone the
object again. Also, maybe one could patch the function that does
the scrolling when entering text to use SET-PARA, so that the
object gets cloned only when, and if, it is needed.
Regards,
Gabriele.
--
Gabriele Santilli <[g--santilli--tiscalinet--it]> -- REBOL Programmer
Amigan -- AGI L'Aquila -- REB: http://web.tiscali.it/rebol/index.r
[5/5] from: anton:lexicon at: 17-Oct-2002 1:11
That's great, Gabriele.
This bug has cropped up a few times and
nobody fixed it until now.
Anton.
Notes
- Quoted lines have been omitted from some messages.
View the message alone to see the lines that have been omitted