|
From: Pau <vim...@go...> - 2012-03-07 19:32:37
|
YES!
The only point is that the label must be included just before the splot command
Thanks a lot...
On 7 March 2012 00:43, Jefferson Stafusa E. Portela <st...@gm...> wrote:
> Didn't resist googling myself. You just have to set the terminal with
> a "colortext" option!
>
> set terminal epslatex color colortext
>
> []s
> Stafusa
>
>
> On Wed, Mar 7, 2012 at 12:36 AM, Jefferson Stafusa E. Portela
> <st...@gm...> wrote:
>> Ok, as I'd said, I have no experience with epslatex, so my solution
>> isn't elegant... but should work.
>>
>> First thing is to include a "front" in your label command:
>> set label textcolor rgb "white" "HOLA" at -20,-20 front
>>
>> Then, and here comes the ugly fix, you should edit the 'output.tex'
>> file and change the line:
>> \put(2570,1600){\makebox(0,0)[l]{\strut{}HOLA}}%
>> to:
>> \put(2570,1600){\makebox(0,0)[l]{\strut{}{\color{white}HOLA}}}%
>> as the gnuplot gives (at least to me) the error:
>> "Package color not loaded in conjunction with terminal option `colourtext'"
>> so the color option is ignored
>>
>> I'd guess it's easy to google for that to solve this part, but now I
>> should go to sleep. :)
>>
>> []s
>> Stafusa
>>
>>
>> On Wed, Mar 7, 2012 at 12:10 AM, Pau <vim...@go...> wrote:
>>> PS: Sorry .... $1 is the argument to pass, namely the data you will
>>> find on that page
>>>
>>>
>>> On 7 March 2012 00:09, Pau <vim...@go...> wrote:
>>>> thanks again for the quick answer....
>>>>
>>>> I made sure it's within the plotting limits but somehow it does not show up
>>>>
>>>> You can try my data, if you wish
>>>>
>>>> http://www.2shared.com/file/TUplOI5P/GasDensityDisc_80.html
>>>>
>>>> The script I was using with gnuplot is
>>>>
>>>> ============
>>>> set terminal epslatex color
>>>> set output "output.tex"
>>>> set size square
>>>> set xlabel textcolor rgb "white" "R"
>>>> set ylabel textcolor rgb "white" "R"
>>>> set mxtics 5
>>>> set mytics 5
>>>> set tics out
>>>> set palette defined ( 0 "black", 1 "black", 2 "blue", 3 "blue", 4
>>>> "orange", 5 "red", 6 "yellow" )
>>>> set pm3d map
>>>> #set autoscale fix
>>>> set xrange [-30:30]
>>>> set yrange [-30:30]
>>>> set cblabel "${\\rm log}_{10} \\, \\left( \\rho_{\\rm gas} \\right)$"
>>>> set object 1 rectangle front from -30,-30 to 30,30 fc rgb "black" behind
>>>> set label textcolor rgb "white" "HOLA" at -10,-10
>>>> splot "'$1'" binary record=384x128 format="%double" u
>>>> ($2*sin($1)):($2*cos($1)):(log10($3)) notitle
>>>> set terminal x11
>>>> ============
>>>>
>>>> thanks again!
>>>>
>>>> On 6 March 2012 23:48, Jefferson Stafusa E. Portela <st...@gm...> wrote:
>>>>> I don't have your data to test your specific example, but that works normally:
>>>>>
>>>>> set object 1 rectangle front from -30,-30 to 30,30 fc rgb "black" behind
>>>>> set label textcolor rgb "white" "HOLA" at -5,-0.5
>>>>> plot sin(x) linecolor rgb "white"
>>>>>
>>>>> You're sure the point -20,-25 is in your plot? If you put the label
>>>>> outside the plot it'll be invisible, of course. If that's not the
>>>>> problem, I can't think now of anything else.
>>>>>
>>>>> []s
>>>>> Stafusa
|