[ncl-talk] Making Space when using textid

Rick Brownrigg brownrig at ucar.edu
Wed Jul 12 09:21:55 MDT 2017


Hi Barry,

without seeing more context of your script, I'm not sure if there's a
better way to do what you want. But you could certainly prepend a space to
the cities; supposing the names are in an array like:

cities = (/ "acbd", "efgh", "ijkl"/)
print(cities)

...then...

labels = " " + cities
print(labels)

Hope that helps,
Rick


On Wed, Jul 12, 2017 at 4:17 AM, Barry Lynn <barry.h.lynn at gmail.com> wrote:

> Hi:
>
> You can see in the attached png that the name of the city is too close to
> the number.
>
> I read the names from a file, so I am unable to manually add space at the
> beginning of each name.
>
> I found a suggestion on the ncl pages, but it doesn't seem to affect the
> position of the number.  The suggested code is in bold below.
>
>   txres               = True       ; Set up text resources
>
>   txres at txFontHeightF = 0.010
>
>   txres at txJust        = "CenterLeft"
>
>   *txres at amParallelPosF = 0.5*
>
>   txt2res               = True       ; Set up text resources
>
>   txt2res at txFontHeightF = 0.010
>
>   txt2res at txJust        = "CenterRight"
>
>   *txt2res at amParallelPosF = -0.5*
> Thank you for your suggestions.
> P.S If there is no good way to do this, is there, perhaps, a way to add
> space at the beginning of the each city string?
>
> Barry
> --
> Barry H. Lynn, Ph.D
> Senior Lecturer,
> The Institute of the Earth Science,
> The Hebrew University of Jerusalem,
> Givat Ram, Jerusalem 91904, Israel
> Tel: 972 547 231 170
> Fax: (972)-25662581
>
> C.E.O, Weather It Is, LTD
> Weather and Climate Focus
> http://weather-it-is.com
> Jerusalem, Israel
> Local: 02 930 9525
> Cell: 054 7 231 170
> Int-IS: x972 2 930 9525
> US 914 432 3108 <(914)%20432-3108>
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170712/aa4a6020/attachment.html 


More information about the ncl-talk mailing list