Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: textbox help
Replies: 4   Last Post: Jan 22, 2012 2:36 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
Jonathan Allan

Posts: 117
Registered: 12/7/04
Re: textbox help
Posted: Jan 22, 2012 2:36 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

>someone" wrote in message <jfca3c$r59$1@newscl01ah.mathworks.com>...
> "Jonathan " <jkakiwi@yahoo.co.uk> wrote in message <jfa2v2$m02$1@newscl01ah.mathworks.com>...

> > Hi,
> >
> > I've developed code to plot a figure with text at specific locations; these locations vary spatially depending on various parameters that are previously selected. What I would like to do is where the text cover lines on the plot, there's a textbox at that location that has a white background color so that the text is clear to see. Is there a way to do this in Matlab. I know wher to place the text but can't figure out how to automatically assign a textbox to that location of a specific size.
> >
> > Thanks
> > Jon

>
> % You should be able to use the BackgroundColor & EdgeColor
> % text propererties to achieve the effects you want.
>
> doc text
>
> % and click on the Text Properties link at the bottom of the page.
> % Use the format:
>
> text(x,y,z,'string','PropertyName',PropertyValue....)


Thanks for the help. However, I'm familiar with using text. What I was trying to do was place a textbox at the same location as my text using code. The latter is easy to do since it can be done by code based on xy parameters that can be specified automatically. However, the former is a little trickier since you are dealing with figure coordinates that are different from data coordinates. In the end I figured out way using a nifty tool called plotboxpos, which finds the position of the axes relative to the figure.



Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.