The only other possible solution is to use copy/paste:
copy line 3 of field 1
paste
Unfortunately, this probably won't work for you since paste always
pastes into the field with the keyboard focus, and always at the
cursor location. Since list boxes don't have a cursor, this probably
won't work in your application. This technique does preserve
attributes, however.
On the other hand, if it's really just for list boxes, the amount of
data you're moving won't be that big and so there shouldn't be any
performance problems doing it the way you've proposed. Also, you
don't have to save the textStyle/textFont for the choices separately,
just get them from the source list box field itself. For example,
putting the following script in the source list box does everything
you need:
on mouseDoubleUp
put the selectedText & return after field "choices"
set the textStyle of the last line of field "choices"\
to the textStyle of the selectedChunk
set the textColor of the last line of field "choices"\
to the textColor of the selectedChunk
end mouseDoubleUp
> In case you are wondering what type of UI I have for this situation. I
> have two list boxes, one of *possible choices*, and another for
> *current choices*. And the user can select items from the possible and
> move them to the current. The items in the possible actually consist of
> several types of things, so they are designated using different Styles
> (bold,italic) and Colour (although the colour may be dropped). Now this
> may not be the best UI technique, but for the situation it isn't as
> confusing as you may think. It may be best to have 3 separate possible
> and current, but that would take up a fair amount of screen area.
I think a better UI technique would be just to use multiple-selection
list boxes. My guess is that people will have a lot of trouble
remembering which color/font goes with which type of thing.
Maintaining the different things in different boxes and allowing
people to select multiple things in each box would probably be easier
for them.
Regards,
Scott
> Thanks for any help.
>
> -Earle
>
> --
> Earle Lowe
> emlowe@fsa.ca
> FSA Corporation
> Performance and system software for UNIX networks.
>
>
-- *********************************************************************** * Scott Raney 303-447-3936 Remember: the better you look, * * raney@metacard.com the more you'll see -- Lidia * ***********************************************************************