positioning graphics in relation to a line in a text field

stephen barncard stephenREVOLUTION2 at barncard.com
Tue Apr 2 14:46:23 EDT 2013


imagesource replaces a text character with a graphic.

The OP wanted a square with transparency to surround a word or phrase in a
text field that looks better than the built in function.


On Tue, Apr 2, 2013 at 11:43 AM, Peter Haworth <pete at lcsql.com> wrote:

> Michael,
> I missed the beginning of this thread so not 100% sure of what you're
> trying to achieve but have you considered  - set the imagesource of char x
> of line y of field "xyz" to 1234?  That makes the image appear at the
> specified location and it scrolls along with everything else.  You may also
> have to use the textshift property of the same char to align the image
> vertically.
> Pete
> lcSQL Software <http://www.lcsql.com>
>
>
> On Tue, Apr 2, 2013 at 10:53 AM, Michael Doub <mikedoub at gmail.com> wrote:
>
> > Thanks Tom.  Mark, what are some of the complications that you mentioned
> > about scrolling fields?   I am thinking about trying to emulate the
> little
> > IOS selection handles.
> >
> > I can see going from the selection to find a location to put the pin
> > graphic, but I am not quite sure how to modify the selection to track the
> > pin movement.
> >
> > -= Mike
> >
> >
> > On Apr 2, 2013, at 12:42 PM, Thomas McGrath III <mcgrath3 at mac.com>
> wrote:
> >
> > > This works really well for me and it will handle multiple selected word
> > on different lines etc. I had a grc that was a dashed box:
> > >
> > > on mouseUp
> > >     put the formattedRect of the selectedChunk into tRect
> > >     put "4" into tMargin
> > >     put item 1 of tRect - tMargin into item 1 of tRect
> > >     put item 3 of tRect + tMargin + 3 into item 3 of tRect
> > >     put item 4 of tRect + tMargin into item 4 of tRect
> > >     set the rect of graphic "Box" to tRect
> > > end mouseUp
> > >
> > > -- Tom McGrath III
> > > http://lazyriver.on-rev.com
> > > mcgrath3 at mac.com
> > >
> > > On Apr 2, 2013, at 11:24 AM, Michael Doub <mikedoub at gmail.com> wrote:
> > >
> > >> Thanks Mark.   I think it is going to be one of those days that I
> might
> > as well stop looking for the forest or the trees.
> > >>
> > >> -= Mike
> > >>
> > >>
> > >> On Apr 2, 2013, at 11:01 AM, Mark Wieder <mwieder at ahsoftware.net>
> > wrote:
> > >>
> > >>> Michael-
> > >>>
> > >>> Tuesday, April 2, 2013, 6:52:57 AM, you wrote:
> > >>>
> > >>>> I must be missing something.  selectedLoc gets you the upper left
> > >>>> corner.  FormattedHeight will allow computation of the lowerLeft.
> > >>>> How do you get the right side?
> > >>>
> > >>> The formattedWidth of the longest line plus the left.
> > >>>
> > >>> --
> > >>> -Mark Wieder
> > >>> mwieder at ahsoftware.net
> > >>>
> > >>>
> > >>> _______________________________________________
> > >>> use-livecode mailing list
> > >>> use-livecode at lists.runrev.com
> > >>> Please visit this url to subscribe, unsubscribe and manage your
> > subscription preferences:
> > >>> http://lists.runrev.com/mailman/listinfo/use-livecode
> > >>
> > >>
> > >> _______________________________________________
> > >> use-livecode mailing list
> > >> use-livecode at lists.runrev.com
> > >> Please visit this url to subscribe, unsubscribe and manage your
> > subscription preferences:
> > >> http://lists.runrev.com/mailman/listinfo/use-livecode
> > >
> > > _______________________________________________
> > > use-livecode mailing list
> > > use-livecode at lists.runrev.com
> > > Please visit this url to subscribe, unsubscribe and manage your
> > subscription preferences:
> > > http://lists.runrev.com/mailman/listinfo/use-livecode
> >
> >
> > _______________________________________________
> > use-livecode mailing list
> > use-livecode at lists.runrev.com
> > Please visit this url to subscribe, unsubscribe and manage your
> > subscription preferences:
> > http://lists.runrev.com/mailman/listinfo/use-livecode
> >
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>



-- 



Stephen Barncard
San Francisco Ca. USA

more about sqb  <http://www.google.com/profiles/sbarncar>



More information about the use-livecode mailing list