[prev in list] [next in list] [prev in thread] [next in thread] 

List:       gnuplot-info
Subject:    Re: Gnuplot question
From:       "Dick Crawford" <crawford () arete ! com>
Date:       2000-02-22 16:46:43
[Download RAW message or body]

On Monday, February 21, 2000 Norm Pos <norm@litel.net> wrote:
    
    
    >I've been asked to fix somebody else's code (!).
    >
    >This is a Visual Basic application which builds a text file of Gnuplot commands. \
>Gnuplot then runs in DOS in the background, creates a  fancy 3D plot, which is \
> >plopped back to a VB window.
    >
    >Question:  How do I place a line of text on the plot page?
    >
    >I've used postscript and LaTex in a prior life, but it has been a while.
    
    gnuplot's basic text-writing command is "set label".  Its syntax is
    
        set label 3 'your advertizement here' at 10,20,30 right font "Times-Roman,24"
    
    The "3" is an ID tag; you can leave this out if you like.  (It allows you to \
reference this particular label to, say, change the size of the font without retyping \
the entire command.)  If there are other labels already on the plot and you don't \
specify the tag, the program will assign an unused one to the new label.  
    The position (I used 10,20,30) is an (x,y,z) triplet, given in the same units as \
your data.  The label will be written horizontally, however, even if you rotate the \
plot (which can be done with "set view").  
    Justification is "right", "left" (which is the default), "center" or "centre" (if \
you learned to spell in Great Britain -- in which case "advertizement" needs an "s" \
not a "z").  
    The font (in case you don't want to use the defaults) must be spelled exactly as \
your output device requires.  
    Is this enough of a hint?
    
    Dick Crawford, aka crawford@arete.com


[Attachment #3 (text/html)]

<!DOCTYPE HTML PUBLIC "-//W3C//DTD W3 HTML//EN">
<HTML>
<HEAD>

<META content=text/html;charset=iso-8859-1 http-equiv=Content-Type><!DOCTYPE HTML \
PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <META content='"MSHTML 4.72.3110.7"' \
name=GENERATOR> <STYLE></STYLE>

</HEAD>
<BODY bgColor=#ffffff>
<BLOCKQUOTE 
style="BORDER-LEFT: #000000 solid 2px; MARGIN-LEFT: 5px; PADDING-LEFT: 5px">
    <DIV><FONT face=Arial size=2>On Monday, February 21, 2000 Norm Pos &lt;<A 
    href="mailto:norm@litel.net">norm@litel.net</A>&gt; 
    wrote:<BR><BR></DIV></FONT>
    <DIV><FONT face=Arial size=2>&gt;I've been asked to fix somebody else's code 
    (!).</FONT></DIV>
    <DIV><FONT color=#000000 size=2>&gt;</FONT></DIV>
    <DIV><FONT face=Arial size=2>&gt;This is a Visual Basic application which 
    builds a text file of Gnuplot commands.&nbsp; &gt;Gnuplot then runs in DOS 
    in the background, creates a&nbsp; fancy 3D plot, which is &gt;plopped back 
    to a VB window.</FONT></DIV>
    <DIV><FONT color=#000000 size=2>&gt;</FONT></DIV>
    <DIV><FONT face=Arial size=2>&gt;Question:&nbsp; How do I place a line of 
    text on the plot page?</FONT></DIV>
    <DIV><FONT color=#000000 size=2>&gt;</FONT></DIV>
    <DIV><FONT face=Arial size=2>&gt;I've used postscript and LaTex in a prior 
    life, but it has been a while.</FONT></DIV>
    <DIV>&nbsp;</DIV>
    <DIV><FONT color=#000000 size=2>gnuplot's basic text-writing command is 
    &quot;set label&quot;.&nbsp; Its syntax is</FONT></DIV>
    <DIV><FONT color=#000000 size=2></FONT>&nbsp;</DIV>
    <DIV><FONT color=#000000 size=2>&nbsp;&nbsp;&nbsp; set label 3 'your 
    advertizement here' at 10,20,30 right font 
    &quot;Times-Roman,24&quot;</FONT></DIV>
    <DIV><FONT color=#000000 size=2></FONT>&nbsp;</DIV>
    <DIV><FONT color=#000000 size=2>The &quot;3&quot; is an ID tag; you can 
    leave this out if you like.&nbsp; (It allows you to reference this 
    particular label to, say, change the size of the font without retyping the 
    entire command.)&nbsp; If there are other labels already on the plot and you 
    don't specify the tag, the program will assign an unused one to the new 
    label.</FONT></DIV>
    <DIV><FONT color=#000000 size=2></FONT>&nbsp;</DIV>
    <DIV><FONT color=#000000 size=2>The position (I used 10,20,30) is an (x,y,z) 
    triplet, given in the same units as your data.&nbsp; The label will be 
    written horizontally, however, even if you rotate the plot (which can be 
    done with &quot;set view&quot;).</FONT></DIV>
    <DIV><FONT color=#000000 size=2></FONT>&nbsp;</DIV>
    <DIV><FONT size=2>Justification is &quot;right&quot;, &quot;left&quot; 
    (which is the default), &quot;center&quot; or &quot;centre&quot; (if you 
    learned to spell in Great Britain -- in which case &quot;advertizement&quot; 
    needs an &quot;s&quot; not a &quot;z&quot;).</FONT></DIV>
    <DIV><FONT size=2></FONT>&nbsp;</DIV>
    <DIV><FONT size=2>The font (in case you don't want to use the defaults) must 
    be spelled exactly as your output device requires.</FONT></DIV>
    <DIV><FONT size=2></FONT>&nbsp;</DIV>
    <DIV><FONT size=2>Is this enough of a hint?</FONT></DIV>
    <DIV><FONT size=2></FONT>&nbsp;</DIV>
    <DIV><FONT size=2>Dick Crawford, aka <A 
    href="mailto:crawford@arete.com">crawford@arete.com</A></FONT></DIV>
    <DIV><FONT color=#000000 size=2></FONT>&nbsp;</DIV></BLOCKQUOTE></BODY></HTML>


 - -
[[[[ to unsubscribe from info-gnuplot, send an email with body
unsubscribe info-gnuplot
to majordomo@dartmouth.edu
]]]]


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic