Frank Riccobono
Frank Riccobono

Reputation: 1063

Any way to prevent gnuplot xticlabel from truncating long strings?

I have a data file with several lines set up like this:

"Simplifying or consolidating services or product portfolios"   .35

When I try to plot this in gnuplot as follows, any string longer than 51 characters is truncated to 52 characters with the last character being a symbol of some sort (e.g. a box, thorn, y umlaut).

plot 'force.dat' u 2 title ' ', '' u 0:(0):xticlabel(1) w l

I haven't been able to find any information about a maximum legnth for xticlabel, but it seems like I've hit the maximum. Is there anything I can do to print out the full string on the graph?

Thanks in advance

Upvotes: 0

Views: 884

Answers (1)

Richard B. Kreckel
Richard B. Kreckel

Reputation: 46

There doesn't seem to be a dynamic way of increasing the length. It is hard-coded.

What you can do is compile your own version where the constant MAX_ID_LEN is set to some reasonably large number (it's defined in file gp_types.h).

(I reported this as a bug.)

Upvotes: 3

Related Questions