From 3894ee90d1d176429d61b57e4f18bb79caa8dec4 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Mon, 9 Jan 2023 21:35:41 -0800 Subject: [PATCH 001/192] plot ... with polygons fillstyle empty really does mean empty Polygons were being treated similarly to "with filledcurves", where "empty" is silently converted to "solid" because for most filledcurves modes there is no usable border so empty would otherwise mean invisible. Arguably "with filledcurves closed" should also allow a true empty fillstyle, but for that you can now use "with polygons" so I left it. --- src/boundary.c | 2 +- src/graphics.c | 9 ++++++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/boundary.c b/src/boundary.c index a66dd89b4..47a0fe0f8 100644 --- a/src/boundary.c +++ b/src/boundary.c @@ -1320,7 +1320,7 @@ do_key_sample( /* need_fill_border will set the border linetype, but candlesticks don't want it */ if ((this_plot->plot_style == CANDLESTICKS && fs->border_color.type == TC_LT && fs->border_color.lt == LT_NODRAW) - || style == FS_EMPTY + || (style == FS_EMPTY && this_plot->plot_style != POLYGONS) || need_fill_border(fs)) { newpath(); draw_clip_line( xl + key_sample_left, yl - key_sample_height/4, diff --git a/src/graphics.c b/src/graphics.c index ce920da89..d67721a4d 100644 --- a/src/graphics.c +++ b/src/graphics.c @@ -1368,7 +1368,13 @@ finish_filled_curve( long side = 0; int i; - if (points <= 0) return; + if (points <= 0) + return; + + /* plot with polygons fs empty really does mean empty (no fill) */ + if (plot->plot_style == POLYGONS && plot->fill_properties.fillstyle == FS_EMPTY) + return; + /* add side (closing) points */ switch (filledcurves_options->closeto) { case FILLEDCURVES_CLOSED: @@ -1503,6 +1509,7 @@ plot_filledcurves(struct curve_points *plot) axis_array[FIRST_Y_AXIS].min, axis_array[FIRST_Y_AXIS].max); break; default: + case FILLEDCURVES_CLOSED: break; } From 7e541a682202c23547ed0598dcf65385063071f4 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Fri, 13 Jan 2023 13:53:38 -0800 Subject: [PATCH 002/192] gd: Change default to "set term png butt truecolor" Newer gdlib versions do a much better job of antialiasing, but only if truecolor is selected so that the library maintains an alpha channel. On the other hand our previous workaround for bad antialiasing, "set term png rounded", has become very slow. Change the default to use the new antialiasing with butt linecaps. The jpeg, gif, and sixel terminals also now default to "butt". --- NEWS | 1 + term/gd.trm | 105 ++++++++++++++++++---------------------------------- 2 files changed, 38 insertions(+), 68 deletions(-) diff --git a/NEWS b/NEWS index 02e86edc8..e2cc0dad5 100644 --- a/NEWS +++ b/NEWS @@ -17,6 +17,7 @@ Changes not in 5.4 * CHANGE criterion for fallback to default axes in 'plot with ellipse' * CHANGE deprecate special case of 'with boxerrorbars" flagged by boxwidth = -2 * CHANGE wgnuplot menu files use UTF-8 encoding +* CHANGE gdlib png terminal defaults to truecolor, antialiasing, butt linecaps Changes in 5.4 ============== diff --git a/term/gd.trm b/term/gd.trm index 0b8f00c52..f4cd9bd02 100644 --- a/term/gd.trm +++ b/term/gd.trm @@ -98,13 +98,14 @@ * Revisit use of brush for thick lines with alpha channel * + setting alpha in the brush itself works OK up to about lw 4. * After that the repeated composition of the brush wipes out the transparency. - * - TODO: - * The brushed line could be written to a separate layer as an opaque object, - * then composited back onto the main canvas with alpha applied. - * term->path(start|end) could wrap that, but as of now the core code doesn't use - * start/end path for most lines. Alternatively it might be triggered by - * term->set_color with alpha channel present and last until the color is changed - * again. + * + * Ethan Merritt Jan 2023: + * Newer antialiasing support in gdlib makes it actually work with the native + * implementation for linewidth > 1. But it requires truecolor. + * Conversely, using the brush alternative (via "rounded") has become very slow. + * CHANGE: + * Default to "set term png butt truecolor" + * gif and sixel default to "butt notruecolor" */ #define GD_DEFINED_COLORS 96 /* Must not exceed size of pm3d_color_names_tbl[] */ @@ -209,7 +210,7 @@ static void PNG_init_brush(int); #ifndef TERM_PROTO_ONLY #ifdef TERM_BODY -static TBOOLEAN PNG_initialized = FALSE; /* Set when terminal first initialized */ +static const char *PNG_initialized = NULL; /* Which terminal was previously used? */ static struct { gdImagePtr image; @@ -641,8 +642,8 @@ PNG_options() unsigned long color; TBOOLEAN gif_anim_option = FALSE; /* set to TRUE if an animated gif option given */ - if (!PNG_initialized) { - PNG_initialized = TRUE; + if (PNG_initialized != term->name) { + PNG_initialized = term->name; term_options[0] = '\0'; term->h_char = PNG_HCHAR; /* Default to medium font */ png_state.default_font = gdfont; @@ -654,10 +655,13 @@ PNG_options() png_state.default_ttfsize = 0; png_state.fontscale = 1; png_state.justify = CENTRE; - png_state.TrueColor = FALSE; PNG_linewidth_factor = 1.0; PNG_dashlength_factor = 1.0; - png_state.capbutt = FALSE; /* to preserve previous default behavior */ + png_state.capbutt = TRUE; /* Change Jan 2023 */ + if (!strcmp(term->name, "gif") || !strcmp(term->name, "sixelgd")) + png_state.TrueColor = FALSE; + else + png_state.TrueColor = TRUE; #ifdef _WIN32 /* Set the default search path for fonts to something useful. */ if (getenv("GDFONTPATH") == NULL) { @@ -676,9 +680,8 @@ PNG_options() } #endif } else { - /* FIXME EAM - these should never happen! */ if (!png_state.default_font) { - fprintf(stderr,"gd.trm: caught initialization error\n"); + int_warn(NO_CARET, "gd.trm: caught initialization error"); png_state.default_font = gdfont; } } @@ -1080,6 +1083,8 @@ PNG_options() term->flags |= TERM_ALPHA_CHANNEL; } else if (png_state.TrueColor) { strcat(term_options, "truecolor "); + } else { + strcat(term_options, "notruecolor "); } if (!(png_state.flags & PNG_USE_CROP)) { strcat(term_options, "no"); @@ -1098,10 +1103,8 @@ PNG_options() sprintf(term_options + strlen(term_options), "dashlength %3.1f ", PNG_dashlength_factor); - if (png_state.capbutt) { - sprintf(term_options + strlen(term_options), - "butt "); - } + sprintf(term_options + strlen(term_options), + png_state.capbutt ? "butt " : "rounded "); if (png_state.animate) { if (strncmp("sixel",term->name,5) == 0) @@ -1251,26 +1254,6 @@ PNG_reset() #endif } -#if 0 -/* use #if 1 that's just for debugging */ -void -PNG_show_current_palette() -{ - int i; - - fprintf(stderr, "*****\n SHOW THE PALETTE! total=%i\n", - gdImageColorsTotal(png_state.image)); - for (i=0; i < gdImageColorsTotal(png_state.image); i++) { - /* Use access macros to learn colors. */ - fprintf(stderr, "%i\tr=%d\t g=%d\tb=%d\n", - i, - gdImageRed(png_state.image,i), - gdImageGreen(png_state.image,i), - gdImageBlue(png_state.image,i)); - } -} -#endif - /* How this works: Gray interval [0;1] will be mapped to interval [0;sm_palette.colors-1] those r,g,b components are mapped by the array @@ -1659,23 +1642,12 @@ PNG_vector(unsigned int x, unsigned int y) /* All other (not dashed) vectors */ } else { - if (png_state.linewidth == 1) { -#if defined(gdAntiAliased) - gdImageSetThickness(png_state.image,1); + if (png_state.capbutt) { + /* Assume working antialiasing (gd version >? 2.0.12) */ + gdImageSetThickness(png_state.image,png_state.linewidth); gdImageSetAntiAliased(png_state.image, png_state.color); gdImageLine(png_state.image, png_state.x, Y(png_state.y), x, Y(y), gdAntiAliased); -#else - gdImageLine(png_state.image, png_state.x, Y(png_state.y), - x, Y(y), png_state.color); -#endif - - } else if (png_state.capbutt){ - - gdImageSetThickness(png_state.image,png_state.linewidth); - gdImageLine(png_state.image, png_state.x, Y(png_state.y), - x, Y(y), png_state.color); - } else { /* EAM - Implement linewidth by using a brush */ PNG_init_brush(lw); @@ -2187,7 +2159,6 @@ ENHGD_put_text(unsigned int x, unsigned int y, const char *str) * punt the string to PNG_put_text() */ if (!strpbrk(str, "{}^_@&~") && !contains_unicode(str)) { - /* FIXME: do something to ensure default font is selected */ PNG_put_text(x,y,str); return; } @@ -2548,15 +2519,18 @@ START_HELP(png) " lines drawn, i.e. they are multiplied by values requested in various drawing", " commands.", "", -" By default output png images use 256 indexed colors. The `truecolor` option", -" instead creates TrueColor images with 24 bits of color information per pixel.", +" By default the png terminal creates TrueColor images with 24 bits of color", +" information per pixel. The `notruecolor` option instead uses only 8 bits,", +" (256 indexed colors).", " Transparent fill styles require the `truecolor` option. See `fillstyle`.", " A transparent background is possible in either indexed or TrueColor images.", +" Antialiasing also requires TrueColor.", "", " `butt` instructs the driver to use a line drawing method that does", " not overshoot the desired end point of a line. This setting is only", -" applicable for line widths greater than 1. This setting is most useful when", -" drawing horizontal or vertical lines. Default is `rounded`.", +" relevant for line widths greater than 1. The alternative is `rounded`,", +" which produces somewhat more uniform curved lines if antialiasing is not", +" available (`notruecolor`) but can be much slower.", "", " The details of font selection are complicated.", " Two equivalent simple examples are given below:", @@ -2571,18 +2545,14 @@ START_HELP(png) "", "2 examples", "?set term png examples", -" set terminal png medium size 640,480 background '#ffffff'", "", -" Use the medium size built-in non-scaleable, non-rotatable font.", -" Use white (24-bit RGB in hexadecimal) for the non-transparent background.", -"", -" set terminal png font arial 14 size 800,600", +" set terminal png font \"arial,14\" size 800,600 background \"white\"", "", " Searches for a scalable font with face name 'arial' and sets the font", " size to 14pt. Please see `fonts` for details of how the font search", " is done.", "", -" set terminal png transparent truecolor enhanced", +" set terminal png transparent enhanced", "", " Use 24 bits of color information per pixel, with a transparent background.", " Use the `enhanced text` mode to control the layout of strings to be printed.", @@ -2700,8 +2670,7 @@ START_HELP(jpeg) "", " `butt` instructs the driver to use a line drawing method that does", " not overshoot the desired end point of a line. This setting is only", -" applicable for line widths greater than 1. This setting is most useful when", -" drawing horizontal or vertical lines. Default is `rounded`.", +" relevant for line widths greater than 1. The alternative is `rounded`.", "", " The details of font selection are complicated.", " Two equivalent simple examples are given below:", @@ -2858,7 +2827,7 @@ START_HELP(gif) " `butt` instructs the driver to use a line drawing method that does", " not overshoot the desired end point of a line. This setting is only", " applicable for line widths greater than 1. This setting is most useful when", -" drawing horizontal or vertical lines. Default is `rounded`.", +" drawing horizontal or vertical lines.", "", " The output plot size is given in pixels---it defaults to 640x480.", " Please see additional information under `canvas` and `set size`.", @@ -3062,8 +3031,8 @@ START_HELP(sixelgd) "", " `butt` instructs the driver to use a line drawing method that does", " not overshoot the desired end point of a line. This setting is only", -" applicable for line widths greater than 1. This setting is most useful when", -" drawing horizontal or vertical lines. Default is `rounded`.", +" relevant for line widths greater than 1. The alternative is `rounded`,", +" which produces somewhat more uniform curved lines but can be much slower.", "", " The details of font selection are complicated.", " For more information please see `fonts`.", From ef681a43b32d8fbb84702fb2a5404690c06be9b4 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Sat, 14 Jan 2023 20:45:36 -0800 Subject: [PATCH 003/192] zsort filter is not available from "stats" don't try to select or call it. --- src/datafile.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/datafile.c b/src/datafile.c index 70fddeeaa..085870885 100644 --- a/src/datafile.c +++ b/src/datafile.c @@ -1328,7 +1328,8 @@ df_open(const char *cmd_filename, int max_using, struct curve_points *plot) /* zsort filter will be applied to this data */ if (equals(c_token, "zsort")) { c_token++; - plot->plot_filter = FILTER_ZSORT; + if (plot) + plot->plot_filter = FILTER_ZSORT; continue; } From 63d5dd420098075bc05d7b90f229f714730def19 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Sun, 15 Jan 2023 20:09:16 -0800 Subject: [PATCH 004/192] default fillstyle for circle/polygon/ellipse objects is now "fs empty border" If you set a linecolor for an empty circle/polygon/ellipse this has the effect of changing the border property. I.e. set obj 1 fs empty set obj 1 lc "red" is now equivalent to set obj 1 fs empty border lc "red" This is a CHANGE. Previously the default was "fs solid border -1 fc bgnd" for circles and ellipses, "fc 'black'" for polygons. Rectangles remain a separate case and are unchanged by this commit. Rectangles have always been treated differently than other object types. --- demo/armillary.dem | 2 +- docs/gnuplot.doc | 8 ++++---- src/gadgets.h | 10 +++++----- src/set.c | 3 +++ 4 files changed, 13 insertions(+), 10 deletions(-) diff --git a/demo/armillary.dem b/demo/armillary.dem index c4b868053..a287f6b45 100644 --- a/demo/armillary.dem +++ b/demo/armillary.dem @@ -49,7 +49,7 @@ array Longitude[13] = [267., 300., 328., 352., 29., 53., 90., 118., 138., 174., do for [i=1:13] { set label i Zodiac[i] at polar Longitude[i], 1.1, 0 center font ",15" set obj i circle at polar Longitude[i], 1.1, 0 radius char 1.5 - set obj i fs solid fc rgb hsv2rgb( Longitude[i]/360., 0.5, 1.0) + set obj i fs solid border lt -1 fc rgb hsv2rgb( Longitude[i]/360., 0.5, 1.0) } # diff --git a/docs/gnuplot.doc b/docs/gnuplot.doc index 7a9cd0381..b343f7247 100644 --- a/docs/gnuplot.doc +++ b/docs/gnuplot.doc @@ -13474,11 +13474,11 @@ Ffigure_multiple_keys subsequent plots. You may define as many objects as you like. Currently the supported object types are `rectangle`, `circle`, `ellipse`, and `polygon`. Rectangles inherit a default set of style properties (fill, color, border) from - those set by the command `set style rectangle`, but each object can also be - given individual style properties. Circles, ellipses, and polygons inherit the - fill style from `set style fill`. Objects to be drawn in 2D plots may be - defined in any combination of axis, graph, polar, or screen coordinates. + those set by the command `set style rectangle`. Every object can be given + individual style properties when it is defined or in a later command. + Objects to be drawn in 2D plots may be defined in any combination of + axis, graph, polar, or screen coordinates. Object specifications in 3D plots cannot use graph coordinates. Rectangles and ellipses in 3D plots are limited to screen coordinates. diff --git a/src/gadgets.h b/src/gadgets.h index dfac5c1a7..923294408 100644 --- a/src/gadgets.h +++ b/src/gadgets.h @@ -611,18 +611,18 @@ extern struct object default_rectangle; extern struct object default_circle; #define DEFAULT_CIRCLE_STYLE { NULL, -1, 0, OBJ_CIRCLE, OBJ_CLIP, \ - {FS_SOLID, 100, 0, BLACK_COLORSPEC}, \ - {0, LT_BACKGROUND, 0, DASHTYPE_SOLID, 0, 0, 1.0, 0.0, DEFAULT_P_CHAR, BACKGROUND_COLORSPEC, DEFAULT_DASHPATTERN}, \ + {FS_EMPTY, 100, 0, {TC_DEFAULT, -2, 0}}, \ + {0, LT_BACKGROUND, 0, DASHTYPE_SOLID, 0, 0, 1.0, 0.0, DEFAULT_P_CHAR, BLACK_COLORSPEC, DEFAULT_DASHPATTERN}, \ {.circle = {1, {0,0,0,0.,0.,0.}, {graph,0,0,0.02,0.,0.}, 0., 360., TRUE }} } extern struct object default_ellipse; #define DEFAULT_ELLIPSE_STYLE { NULL, -1, 0, OBJ_ELLIPSE, OBJ_CLIP, \ - {FS_SOLID, 100, 0, BLACK_COLORSPEC}, \ - {0, LT_BACKGROUND, 0, DASHTYPE_SOLID, 0, 0, 1.0, 0.0, DEFAULT_P_CHAR, BACKGROUND_COLORSPEC, DEFAULT_DASHPATTERN}, \ + {FS_EMPTY, 100, 0, {TC_DEFAULT, -2, 0}}, \ + {0, LT_BACKGROUND, 0, DASHTYPE_SOLID, 0, 0, 1.0, 0.0, DEFAULT_P_CHAR, BLACK_COLORSPEC, DEFAULT_DASHPATTERN}, \ {.ellipse = {ELLIPSEAXES_XY, {0,0,0,0.,0.,0.}, {graph,graph,0,0.05,0.03,0.}, 0. }} } #define DEFAULT_POLYGON_STYLE { NULL, -1, 0, OBJ_POLYGON, OBJ_CLIP, \ - {FS_SOLID, 100, 0, BLACK_COLORSPEC}, \ + {FS_EMPTY, 100, 0, {TC_DEFAULT, -2, 0}}, \ {0, LT_BLACK, 0, DASHTYPE_SOLID, 0, 0, 1.0, 0.0, DEFAULT_P_CHAR, BLACK_COLORSPEC, DEFAULT_DASHPATTERN}, \ {.polygon = {0, NULL} } } diff --git a/src/set.c b/src/set.c index c6d0c7adf..84d7d8303 100644 --- a/src/set.c +++ b/src/set.c @@ -4348,6 +4348,9 @@ set_obj(int tag, int obj_type) if (!got_lt) { lp_style_type lptmp = this_object->lp_properties; lp_parse(&lptmp, LP_NOFILL, FALSE); + if (this_object->fillstyle.fillstyle == FS_EMPTY) { + this_object->fillstyle.border_color = lptmp.pm3d_color; + } if (c_token != save_token) { this_object->lp_properties.l_width = lptmp.l_width; this_object->lp_properties.d_type = lptmp.d_type; From fbbf913521f335bd19dc267ce6880b8af47f3902 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Sun, 15 Jan 2023 23:38:21 -0800 Subject: [PATCH 005/192] remove option ./configure --with-cwdrc Old configuration message: Check current directory for .gnuplot file - normally disabled for security reasons This option has been disrecommended for a long time as a security hazard. Addition of support for XDG directory conventions in version 5 would seem to make it even less necessary than before. --- configure.ac | 15 --------------- docs/gnuplot.doc | 6 ++---- src/plot.c | 13 ++----------- src/show.c | 7 +------ 4 files changed, 5 insertions(+), 36 deletions(-) diff --git a/configure.ac b/configure.ac index 3d53f9fb7..d877eac6f 100644 --- a/configure.ac +++ b/configure.ac @@ -741,15 +741,6 @@ dnl end caca dnl Process rest of with and enable options -dnl Use .gnuplot file in current directory -AC_ARG_WITH(cwdrc,dnl -[ --with-cwdrc check current directory for .gnuplot file, - normally disabled for security reasons],,) -if test "$with_cwdrc" = yes; then - AC_DEFINE(USE_CWDRC,1, - [ Define if you want to read .gnuplot from current directory (SECURITY RISK!).]) -fi - dnl without-extra-coordinate may leave a hole in "struct coordinate" AC_ARG_WITH(extra-coordinate,dnl [ --without-extra-coordinate leave possible hole in struct coordinate],,) @@ -1461,12 +1452,6 @@ else AC_MSG_RESULT([ Command-line history file: no]) fi -if test "$with_cwdrc" = yes; then - AC_MSG_RESULT([ Check current directory for .gnuplot file: yes (warning: security risk)]) -else - AC_MSG_RESULT([ Check current directory for .gnuplot file: no (use --with-cwdrc to enable)]) -fi - if test "$with_row_help" = no; then AC_MSG_RESULT([ Sort help/subtopic tables by column: yes]) else diff --git a/docs/gnuplot.doc b/docs/gnuplot.doc index b343f7247..6e0dd7acb 100644 --- a/docs/gnuplot.doc +++ b/docs/gnuplot.doc @@ -4114,11 +4114,9 @@ Ffigure_newsyntax and is reported by `show loadpath`. The program then looks in the user's HOME directory for a file called `.gnuplot` on Unix-like systems or `GNUPLOT.INI` on other systems. (OS/2 will look for it in the directory named in - the environment variable `GNUPLOT`; Windows will use `APPDATA`). On Unix-like - systems gnuplot additionally checks for the file + the environment variable `GNUPLOT`; Windows will use `APPDATA`). + On Unix-like systems gnuplot additionally checks for the file $XDG_CONFIG_HOME/gnuplot/gnuplotrc. - Note: The program can be configured to look first in the current directory, - but this is not recommended because it is bad security practice. 2 String constants, string variables, and string functions ?string ?strings diff --git a/src/plot.c b/src/plot.c index bfefd74bc..5ff7273d3 100644 --- a/src/plot.c +++ b/src/plot.c @@ -770,7 +770,6 @@ init_session() */ reset_command(); /* FIXME: this does c_token++ */ load_rcfile(0); /* System-wide gnuplotrc if configured */ - load_rcfile(1); /* ./.gnuplot if configured */ /* After this point we allow pipes and system commands */ successful_initialization = TRUE; @@ -782,8 +781,8 @@ init_session() /* * Read commands from an initialization file. * where = 0: look for gnuplotrc in system shared directory - * where = 1: look for .gnuplot in current directory - * where = 2: look for .gnuplot in home directory + * where = 1: look for .gnuplot in current directory (DEPRECATED) + * where = 2: look for .gnuplot in user's home directory */ static void load_rcfile(int where) @@ -806,14 +805,6 @@ load_rcfile(int where) plotrc = fopen(rcfile, "r"); #endif - } else if (where == 1) { -#ifdef USE_CWDRC - /* Allow check for a .gnuplot init file in the current directory */ - /* This is a security risk, as someone might leave a malicious */ - /* init file in a shared directory. */ - plotrc = fopen(PLOTRC, "r"); -#endif /* !USE_CWDRC */ - } else if (where == 2 && user_homedir) { /* length of homedir + directory separator + length of file name + \0 */ int len = (user_homedir ? strlen(user_homedir) : 0) + 1 + strlen(PLOTRC) + 1; diff --git a/src/show.c b/src/show.c index 7ed60be1a..11563d4b2 100644 --- a/src/show.c +++ b/src/show.c @@ -1002,12 +1002,7 @@ show_version(FILE *fp) ""; const char *nocwdrc = -#ifdef USE_CWDRC - "+" -#else - "-" -#endif - "USE_CWDRC "; + "-USE_CWDRC "; const char *x11 = #ifdef X11 From 237cc8928406c400c4f8223b4a74852ec815c71f Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Mon, 16 Jan 2023 10:39:26 -0800 Subject: [PATCH 006/192] remove option ./configure --with-tutorial The LaTeX tutorial was based on old latex terminals that are no longer supported. It was functionally replaced by a latex terminal demo demo/latex_demo.tex. The tutorial was already removed as a top level build target by commit f623755. Now it is not listed as a configure option. --- configure.ac | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/configure.ac b/configure.ac index d877eac6f..7d797dbfd 100644 --- a/configure.ac +++ b/configure.ac @@ -759,13 +759,13 @@ AC_ARG_WITH(row-help,dnl fi]) dnl Whether we want to create the LaTeX tutorial -TUTORIAL=notutorial -AC_ARG_WITH(tutorial,dnl -[ --with-tutorial process the LaTeX tutorial when building]) -dnl only if latex/2e is found -if test "$with_latex" != no -a "$with_tutorial" = yes ; then - TUTORIAL=tutorial -fi +dnl TUTORIAL=notutorial +dnl AC_ARG_WITH(tutorial,dnl +dnl [ --with-tutorial process the LaTeX tutorial when building]) +dnl dnl only if latex/2e is found +dnl if test "$with_latex" != no -a "$with_tutorial" = yes ; then +dnl TUTORIAL=tutorial +dnl fi dnl enable multi-byte font support in x11 terminal AC_ARG_ENABLE(x11-mbfonts,dnl @@ -805,11 +805,11 @@ AC_ARG_ENABLE(raise-console,dnl dnl -if test ! -f src/graphics.c ; then - AC_MSG_RESULT([Compiling outside source directory - copying needed files]) - mkdir tutorial >/dev/null 2>&1 - cp ${srcdir}/tutorial/eg3.dat tutorial -fi +dnl if test ! -f src/graphics.c ; then +dnl AC_MSG_RESULT([Compiling outside source directory - copying needed files]) +dnl mkdir tutorial >/dev/null 2>&1 +dnl cp ${srcdir}/tutorial/eg3.dat tutorial +dnl fi dnl wxWidgets terminal @@ -1203,7 +1203,7 @@ AC_SUBST(GIHDIR) AC_SUBST(TEXDIR) AC_SUBST(TERMLIBS) AC_SUBST(TERMXLIBS) -AC_SUBST(TUTORIAL) +dnl AC_SUBST(TUTORIAL) dnl Write Makefiles and configuration header AC_CONFIG_FILES([Makefile From 02b39a81ecca5bd1aba4920928c84aa03582cdad Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Wed, 18 Jan 2023 15:11:23 -0800 Subject: [PATCH 007/192] sanity check format passed to sprintf Unfortunately snprintf can segfault if passed non-ascii bytes in a format string, e.g. snprintf( out, n, "%2f", x) We were already checking for illegal ascii characters; now we check for non-ascii characters also. Found by fuzzing input. --- src/internal.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/internal.c b/src/internal.c index aa64f4357..099bf9f26 100644 --- a/src/internal.c +++ b/src/internal.c @@ -2045,6 +2045,7 @@ sprintf_specifier(const char* format) const char illegal_spec[] = "hlLqjzZtCSpn*"; int string_pos, real_pos, int_pos, illegal_pos; + int nonascii_pos; /* check if really format specifier */ if (format[0] != '%') @@ -2056,6 +2057,15 @@ sprintf_specifier(const char* format) int_pos = strcspn(format, int_spec); illegal_pos = strcspn(format, illegal_spec); + /* Unfortunately snprintf can segfault on weird bytes in the format */ + for (nonascii_pos=0; format[nonascii_pos]; nonascii_pos++) { + if (!isascii(format[nonascii_pos])) + break; + } + if ( nonascii_pos < int_pos && nonascii_pos < real_pos + && nonascii_pos < string_pos ) + return INVALID_NAME; + if ( illegal_pos < int_pos && illegal_pos < real_pos && illegal_pos < string_pos ) return INVALID_NAME; From 0dd4d22971df4642a1c794b57ca07e490c7ce986 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Thu, 19 Jan 2023 10:36:21 -0800 Subject: [PATCH 008/192] better memory allocation bookkeeping for filters + smoothing Several filters or smoothing operations replace the original plot->points array with a new one holding the smoothed data points. If they neglect to update the corresponding bookkeeping data in the header, it could lead to memory corruption. (plot->p_max, plot->varcolor, etc). Call cp_extend, which gets it right, instead of simply doing plot->points = alloc(...). Affects grid_polar_data(), make_bins(), convex_hull(). --- src/filters.c | 10 +++++----- src/plot2d.c | 7 ++++--- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/src/filters.c b/src/filters.c index 0df39f9b9..613322acc 100644 --- a/src/filters.c +++ b/src/filters.c @@ -312,7 +312,7 @@ make_bins(struct curve_points *plot, int nbins, * new z = number of points in the bin */ plot->p_count = nbins; - plot->points = gp_realloc( plot->points, nbins * sizeof(struct coordinate), "curve_points"); + cp_extend(plot, nbins); for (i=0; ipoints = points; + cp_extend(plot, 4); + plot->points[3] = plot->points[0]; plot->p_count = 4; return; } @@ -841,10 +840,11 @@ convex_hull(struct curve_points *plot) points = gp_alloc( np * sizeof(struct coordinate), "Hull" ); for (i=0; ipoints); + cp_extend(plot, 0); free(stack); plot->points = points; plot->p_count = np; + plot->p_max = np; } #undef CROSS diff --git a/src/plot2d.c b/src/plot2d.c index d3d86bf17..5cf1d4abe 100644 --- a/src/plot2d.c +++ b/src/plot2d.c @@ -164,7 +164,6 @@ cp_extend(struct curve_points *cp, int num) /* true end in case two slots are used at once */ /* (e.g. redundant final point of closed curve) */ } else { - /* FIXME: Does this ever happen? Should it call cp_free() instead? */ free(cp->points); cp->points = NULL; cp->p_max = 0; @@ -4250,10 +4249,12 @@ grid_polar_data(struct curve_points *this_plot) /* Create the new grid structure and fill in grid point values * derived from the original data point values. */ + this_plot->points = NULL; + cp_extend(this_plot, 0); this_plot->p_count = polar_grid.theta_segments * polar_grid.r_segments; - this_plot->points = gp_alloc( sizeof(coordinate) * this_plot->p_count, "polar grid"); - point = this_plot->points; + cp_extend(this_plot, this_plot->p_count); + point = this_plot->points; for (i = 0, r = rmin; i < polar_grid.r_segments; i++, r += dr) { for (j = 0, t = tmin; j < polar_grid.theta_segments; j++, t+=dt, point++) { opoint = old_points; From d2f105dc12e47776ae1ccc34be1ff104982bd145 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Thu, 19 Jan 2023 14:54:51 -0800 Subject: [PATCH 009/192] allterms-ja: include recent changes to gd.trm help text --- docs/allterm-ja.h | 28 +++++++++++++--------------- 1 file changed, 13 insertions(+), 15 deletions(-) diff --git a/docs/allterm-ja.h b/docs/allterm-ja.h index 6a2377558..0ddb7d37b 100644 --- a/docs/allterm-ja.h +++ b/docs/allterm-ja.h @@ -3820,7 +3820,7 @@ START_HELP(gif) " `butt` instructs the driver to use a line drawing method that does", " not overshoot the desired end point of a line. This setting is only", " applicable for line widths greater than 1. This setting is most useful when", -" drawing horizontal or vertical lines. Default is `rounded`.", +" drawing horizontal or vertical lines.", "", " The output plot size is given in pixels---it defaults to 640x480.", " Please see additional information under `canvas` and `set size`.", @@ -4333,8 +4333,7 @@ START_HELP(jpeg) "", " `butt` instructs the driver to use a line drawing method that does", " not overshoot the desired end point of a line. This setting is only", -" applicable for line widths greater than 1. This setting is most useful when", -" drawing horizontal or vertical lines. Default is `rounded`.", +" relevant for line widths greater than 1. The alternative is `rounded`.", "", " The details of font selection are complicated.", " Two equivalent simple examples are given below:", @@ -5269,15 +5268,18 @@ START_HELP(png) " lines drawn, i.e. they are multiplied by values requested in various drawing", " commands.", "", -" By default output png images use 256 indexed colors. The `truecolor` option", -" instead creates TrueColor images with 24 bits of color information per pixel.", +" By default the png terminal creates TrueColor images with 24 bits of color", +" information per pixel. The `notruecolor` option instead uses only 8 bits,", +" (256 indexed colors).", " Transparent fill styles require the `truecolor` option. See `fillstyle`.", " A transparent background is possible in either indexed or TrueColor images.", +" Antialiasing also requires TrueColor.", "", " `butt` instructs the driver to use a line drawing method that does", " not overshoot the desired end point of a line. This setting is only", -" applicable for line widths greater than 1. This setting is most useful when", -" drawing horizontal or vertical lines. Default is `rounded`.", +" relevant for line widths greater than 1. The alternative is `rounded`,", +" which produces somewhat more uniform curved lines if antialiasing is not", +" available (`notruecolor`) but can be much slower.", "", " The details of font selection are complicated.", " Two equivalent simple examples are given below:", @@ -5292,18 +5294,14 @@ START_HELP(png) "", "2 examples", "?set term png examples", -" set terminal png medium size 640,480 background '#ffffff'", "", -" Use the medium size built-in non-scaleable, non-rotatable font.", -" Use white (24-bit RGB in hexadecimal) for the non-transparent background.", -"", -" set terminal png font arial 14 size 800,600", +" set terminal png font \"arial,14\" size 800,600 background \"white\"", "", " Searches for a scalable font with face name 'arial' and sets the font", " size to 14pt. Please see `fonts` for details of how the font search", " is done.", "", -" set terminal png transparent truecolor enhanced", +" set terminal png transparent enhanced", "", " Use 24 bits of color information per pixel, with a transparent background.", " Use the `enhanced text` mode to control the layout of strings to be printed.", @@ -6676,8 +6674,8 @@ START_HELP(sixelgd) "", " `butt` instructs the driver to use a line drawing method that does", " not overshoot the desired end point of a line. This setting is only", -" applicable for line widths greater than 1. This setting is most useful when", -" drawing horizontal or vertical lines. Default is `rounded`.", +" relevant for line widths greater than 1. The alternative is `rounded`,", +" which produces somewhat more uniform curved lines but can be much slower.", "", " The details of font selection are complicated.", " For more information please see `fonts`.", From 1ceec2ab7aa343b069801e1f3573014ce79169c3 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Thu, 19 Jan 2023 16:55:48 -0800 Subject: [PATCH 010/192] bugfix: border color for filled curves and polygons with variable fillcolor The filled area of a filled curve is drawn first. If the fillstyle has a border a separate call to plot_lines() is then made. Polygons are the same. But plot_lines() checks for variable color again and gets the fill color not the border color. Disable this check for plot styles filledcurves and polygons. --- docs/gnuplot.doc | 1 + src/graphics.c | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/docs/gnuplot.doc b/docs/gnuplot.doc index 6e0dd7acb..252a164ca 100644 --- a/docs/gnuplot.doc +++ b/docs/gnuplot.doc @@ -5843,6 +5843,7 @@ Ffigure_points specifier and the keywords `lc variable` (value is interpreted as a linetype) or `lc rgb variable` (value is interpreted as a 24-bit RGB color). Only the color value from the first vertex of the polygon is used. + The border line type, if any, is taken from the fill style. 3D plots: diff --git a/src/graphics.c b/src/graphics.c index d67721a4d..34615980c 100644 --- a/src/graphics.c +++ b/src/graphics.c @@ -1271,8 +1271,13 @@ plot_lines(struct curve_points *plot) (void)zprev; /* prevents unused variable warning #ifndef USE_WATCHPOINTS */ - /* rgb variable - color read from data column */ - check_for_variable_color(plot, &plot->varcolor[i]); + /* rgb variable or palette z - color is read from data column + * Exception: + * If we are retracing the border of a filled curve or polygon + * the color has already been set to the border color. + */ + if (plot->plot_style != FILLEDCURVES && plot->plot_style != POLYGONS) + check_for_variable_color(plot, &plot->varcolor[i]); /* Only map and plot the point if it is well-behaved (not UNDEFINED). * Note that map_x or map_y can hit NaN during eval_link_function(), From 44bf052a0ba128aaf57aa2da73a0ed0da15f4292 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Fri, 20 Jan 2023 16:35:55 -0800 Subject: [PATCH 011/192] parsing error: plot foo=1, for [i=1:N] ... An iteration immediately following a definition in a plot or splot command was not parsed. Arguably this is not a reasonable thing to do anyhow, as it should be foo=1; plot for [i=1:N] ... but it's fixable so fix it. Bug #2580 --- src/plot2d.c | 20 +++++++++++++++----- src/plot3d.c | 18 ++++++++++++++---- 2 files changed, 29 insertions(+), 9 deletions(-) diff --git a/src/plot2d.c b/src/plot2d.c index 5cf1d4abe..aaee70338 100644 --- a/src/plot2d.c +++ b/src/plot2d.c @@ -2225,8 +2225,13 @@ eval_plots() define(); if (equals(c_token,",")) c_token++; - was_definition = TRUE; - continue; + if (equals(c_token,"for")) + /* fall through to iteration check at the end of the loop */ + c_token--; + else { + was_definition = TRUE; + continue; + } } else { int specs = 0; @@ -3295,7 +3300,7 @@ eval_plots() this_plot->sample_var2->udv_value = original_value_sample_var2; } - } /* !is_defn */ + } /* !is_definition */ if (in_parametric) { if (equals(c_token, ",")) { @@ -3423,8 +3428,13 @@ eval_plots() define(); if (equals(c_token, ",")) c_token++; - was_definition = TRUE; - continue; + if (equals(c_token,"for")) + /* fall through to iteration check at the end of the loop */ + c_token--; + else { + was_definition = TRUE; + continue; + } } else { struct at_type *at_ptr; diff --git a/src/plot3d.c b/src/plot3d.c index f83cb039b..c273f7bba 100644 --- a/src/plot3d.c +++ b/src/plot3d.c @@ -1654,8 +1654,13 @@ eval_3dplots() define(); if (equals(c_token, ",")) c_token++; - was_definition = TRUE; - continue; + if (equals(c_token,"for")) { + /* fall through to iteration check at the end of the loop */ + c_token--; + } else { + was_definition = TRUE; + continue; + } } else { int specs = -1; @@ -2606,8 +2611,13 @@ eval_3dplots() define(); if (equals(c_token,",")) c_token++; - was_definition = TRUE; - continue; + if (equals(c_token,"for")) { + /* fall through to iteration check at the end of the loop */ + c_token--; + } else { + was_definition = TRUE; + continue; + } } else { struct at_type *at_ptr; From c272ced5ea49417664d5776b451d89b3d8adb3c2 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Fri, 20 Jan 2023 21:13:31 -0800 Subject: [PATCH 012/192] remove conditional compilation for PM3D_INTERSECTING_SURFACES --- src/pm3d.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/pm3d.c b/src/pm3d.c index ebdc70777..577d73c16 100644 --- a/src/pm3d.c +++ b/src/pm3d.c @@ -100,10 +100,7 @@ static TBOOLEAN reserve_quadrangles(int needed, int chunk); static gpdPoint *get_polygon(int size); static void free_polygonlist(void); -#define PM3D_INTERSECTING_SURFACES -#ifdef PM3D_INTERSECTING_SURFACES static void split_intersecting_surface_tiles(void); -#endif /* * Utility routines. @@ -380,9 +377,7 @@ void pm3d_depth_queue_flush(void) if (pm3d.direction != PM3D_DEPTH && !track_pm3d_quadrangles) return; -#ifdef PM3D_INTERSECTING_SURFACES split_intersecting_surface_tiles(); -#endif term->layer(TERM_LAYER_BEGIN_PM3D_FLUSH); @@ -1877,7 +1872,6 @@ pm3d_reset_after_error() free_polygonlist(); } -#ifdef PM3D_INTERSECTING_SURFACES /* * Ethan Merritt Sep 2021 * When two pm3d surfaces intersect, the intersection line is jagged because @@ -2112,4 +2106,3 @@ split_intersecting_surface_tiles() } } -#endif /* PM3D_INTERSECTING_SURFACES */ From f2a1b738e3eaff2c38f6b7825a85808cbb22f5fb Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Sat, 21 Jan 2023 12:24:52 -0800 Subject: [PATCH 013/192] update README and INSTALL files --- INSTALL | 113 +++++++++++++++----------------------------------------- README | 48 +++--------------------- 2 files changed, 35 insertions(+), 126 deletions(-) diff --git a/INSTALL b/INSTALL index daa308415..9e614b90c 100644 --- a/INSTALL +++ b/INSTALL @@ -117,12 +117,10 @@ can be controlled in different ways: make X11_DRIVER_DIR='/gnuplot/lib/4.0' gnuplot_x11 will be installed as /gnuplot/lib/4.0/gnuplot_x11 -If you don't install the program at the place chosen by ./configure, + If you don't install the program at the place chosen by ./configure, e.g. by overriding the "prefix" at "make install" time, files written -by the `save' command cannot be used as scripts on Un*x platforms, so -this should be avoided. There is no way to specify the location of -the executables during runtime. Other platforms are not affected by -this. +by the `save' command cannot be used as self-executing scripts on Un*x +platforms (but they still work as input scripts to gnuplot). The gnuplot demo files are not installed by default, mainly because there is no universally agreed place where such files should go. @@ -150,37 +148,30 @@ to change. A complete list of options is available through $ ./configure --help - Some options relevant to gnuplot are listed below: - - --prefix=PREFIX Install architecture-independent files in PREFIX - [/usr/local] - --exec-prefix=EPREFIX Install architecture-specific file in EPREFIX - [PREFIX] - --bindir=DIR user executables in DIR [EPREFIX/bin] - The gnuplot binary is installed this directory - --libexecdir=DIR program executables in DIR [EPREFIX/libexec] - gnuplot_x11 goes into $libexecdir/gnuplot/. - --datadir=DIR Read-only architecture-independent data in DIR - [PREFIX/share]. The gnuplot help file is installed - in this directory. - --libdir=DIR object code libraries in DIR [EPREFIX/lib] - --includedir=DIR C header files in DIR [PREFIX/include] - --mandir=DIR Man documentation in DIR [PREFIX/man] + Many of the available options are generic to programs built with the + autotools/autoconf build system. + Some options specifically relevant to gnuplot are listed below: --disable-history-file do not use history file - --disable-mouse disable mouse for interactive terminals - --disable-x11-mbfonts disable multi-byte font support for x11 - --disable-x11-external disable drawing to windows belonging to external apps - --disable-raise-console spacebar in plot window does not raise console - --disable-wxwidgets wxWidgets terminal (default enabled) - --enable-backwards-compatibility enable deprecated syntax - - --with-bitmap-terminals enable support for HP deskjet era dot matrix printers - and *.pbm files + --without-latex do not install latex support files + --with-textdir=DIR where to install latex support files + --without-tektronix do not include tektronix terminal emulators + --with-readline={gnu|bsd|builtin} Override the automatic choice of terminal input modes. See below for more detail. + Source files for many older terminal types, legacy output modes, and +hardware or platform-specific devices are included in the distribution. +These can be included in the gnuplot executable by selecting a corresponding +configure option. For example to build in support for physical terminals or +terminal emulators that accept Tektronix graphics protocols (1970s-1980s), +and also build in support for a large set of 1990s era dot matrix printers +(HP deskjet, epson, tandy, etc): + + ./configure --with-tektronix --with-bitmap-terminals + + Options marked with (*) are enabled by default, ie. these features or packages are used if configure detects them even if the corresponding option is not specified. Please note that the `--with-PACKAGE' @@ -232,12 +223,17 @@ Readline issues: wxt terminal: + This interactive terminal is in principle cross-platform and you needn't + do anything special. However if you discover that practice diverges from + principle, the notes below that were collected from problems encountered + in the past might help. + Cairo & pango need to be installed first on Mac, I recommend using MacPorts building universal (i386 libraries): sudo port install cairo +no_x11 +quartz +universal sudo port install pango +no_x11 +quartz +universal - Next gnuplot may be compiled with shipped with Mac OS X 10.6 SL wxWidgets using: + Next gnuplot may be compiled with Mac OS X 10.6 SL wxWidgets using: ./configure CPPFLAGS='-arch i386' LDFLAGS='-arch i386' NOTE: 10.6 SL by default generates x86_64 code, but wxWidgets stable is using @@ -252,47 +248,6 @@ wxt terminal: If you have the option of linking to libraries for wxgtk 2.8 instead, this may be preferable. The -lX11 flag is not need in this case. -VMS ---- - - John Hasstedt has written configure.vms, -a command file that creates the necessary make and option files to build -gnuplot. See the file for instructions on using it. If you have problems -with it, the old build files are still included; instructions for using -them follow. - - On VMS, you can use MMS, MMK, or another make utility, or you can -use BUILDVMS.COM. The supplied files work with Alpha/VMS V6.2 and -DECC V5.7; you may get warnings or more serious errors depending on -the versions of the C compiler, the C run-time libraries, and VMS on -your system. - - To compile using MMK: - MMK/DESCRIPTION=MAKEFILE.VMS - To compile using MMS on VAX: - MMS/DESCRIPTION=MAKEFILE.VMS - To compile using MMS on Alpha: - MMS/DESCRIPTION=MAKEFILE.VMS/MACRO=__ALPHA__=1 - - Alternatively, you can use MAKE_VMS.COM. This command file will run -MMK or MMS to build gnuplot. If you don't have either one installed, it -will use the command file. The first parameter on the command line is -the compiler you want to use (default DECC). - - It may sometimes be useful to add `/IGNORE=WARNING' to the `MMS' call. - - To compile using GNUC or VAXC: - add /MACRO=GNUC or /MACRO=VAXC to the above command - To compile with another make utility: - check the documentation of your utility to specify the description - file and any necessary macros (__ALPHA__, GNUC, or VAXC) - Or if you don't have a suitable make: - @BUILDVMS - To tell gnuplot where to find the help library: - $ define gnuplot$help disk:[directory]gnuplot.hlb - Alternatively, put the help in the main system help library. - - MS-Windows ---------- @@ -420,8 +375,8 @@ Platform compiler problems This section addresses trouble shooting and testing issues. Userland questions are answered in the FAQ. -Platform and compiler notes ---------------------------- +Platform and compiler notes (probably long out of date) +------------------------------------------------------- Generally, if you think that configure has made a mistake in detecting platform features, you should consider that a bug either in GNU autoconf @@ -540,16 +495,6 @@ to the CGI agents, and the CGIDISP and/or CGIPRNT environment variables to the CGI agents, and the CGIDISP and/or CGIPRNT environment variables to set the output devices. -If creating dynamically linked executables, it may be necessary to add -flags to the LIBS variable in Makefile to make sure gnuplot finds all -required libraries at runtime. Systems like SunOS and Solaris use -R -to specify the runtime library search path, whereas OSF/Dec Unix, Irix -and Linux use -rpath. If this is not possible, the LD_LIBRARY_PATH -environment variable should be set. Generally it's recommended to -install shared libraries only in places that are already searched by -the linker without such options. LD_LIBRARY_PATH is the second-best -choice. - How to test gnuplot =================== diff --git a/README b/README index b40d1b154..6cac8c3a5 100644 --- a/README +++ b/README @@ -69,9 +69,8 @@ page, also at SourceForge: http://sourceforge.net/projects/gnuplot/ - Note that since gnuplot has nothing to do with the GNU project, please -don't ask them for help or information about gnuplot; also, please -don't ask us about GNU stuff. + There are separate tracking systems for Feature Requests and proposed +patches that implement new features, also hosted at SourceForge. All bug reports should include the version of gnuplot you are using, the operating system and version you are running it on, and the output @@ -79,13 +78,6 @@ device (gnuplot's "terminal") that you are plotting to. It helps a lot to provide a simple script, possibly with data, that reproducibly demonstrates the problem you are reporting. -Usenet -====== - - Additional help can be obtained from the USENET newsgroup - - comp.graphics.apps.gnuplot - Mailing Lists ============= @@ -95,38 +87,10 @@ the web interface at http://sourceforge.net/mail/?group_id=2055 - The main lists you may be interested in are "gnuplot-info" and -"gnuplot-bugs". "gnuplot-info" is for general discussion and -questions about how to use the program. But as noted above, -using the Usenet newsgroup for this kind of communication is -almost certainly better both for you and for us. - - "gnuplot-bugs" is NOT an appropriate place to ask questions on how to -solve a gnuplot problem or even to report a bug that you haven't -investigated personally. It is far more likely you'll get the help -you need for this kind of problem from comp.graphics.apps.gnuplot -or the gnuplot-info mailing list. - - Using "gnuplot-bugs" is also slightly disfavoured, because it makes it -hard for us to keep track what bugs are currently under investigation, -and hard for you to check if maybe the bug you've found has already -been reported by somebody else before. We would thus like to ask to -you please use the "Bug Tracker" system that is part of gnuplot's -development web site at SourceForge.net instead of this mailing list. - - If you found a fix already, pleast post it in "diff -c" or "diff -u" -format done against the most current official version of gnuplot or -a snapshot of the current development source. Major modifications should -include documentation and, if new features were added, a demo file. -Finally, it is much easier to integrate smaller stepwise modifications -rather than one gigantic diff file which represents months of changes. - - There are separate tracking systems for Feature Requests and proposed -patches that implement new features, also hosted at SourceForge. - - Discussions about plans for new features or other significant changes -should be announced and discussed on the developers' mailing list, -gnuplot-beta, which is also hosted by SourceForge.net. + The lists you may be interested in are "gnuplot-info" and "gnuplot-beta". +"gnuplot-info" is for general discussion and questions about how to use +the program. "gnuplot-beta" is for discussion about possible new features, +plans for future work, release schedules, or other development issues. ---- From f943d63b7b5b9dec8435fd06c2a0e56945e942e3 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Sat, 21 Jan 2023 12:33:40 -0800 Subject: [PATCH 014/192] clean up output from ./configure Mostly just fixes column alignment of the configuration summary --- configure.ac | 121 ++++++++++++++++++++++++++------------------------- 1 file changed, 61 insertions(+), 60 deletions(-) diff --git a/configure.ac b/configure.ac index 7d797dbfd..8d2bda12c 100644 --- a/configure.ac +++ b/configure.ac @@ -114,7 +114,7 @@ if test "${with_libcerf}" = yes ; then fi AC_ARG_WITH(amos,dnl -[ --with-amos[=DIR] location of libamos or libopenspecfun (complex functions)],, +[ --with-amos[=DIR] location of libamos or libopenspecfun (complex functions)],, with_amos=yes) if test -d "$with_amos"; then @@ -1025,7 +1025,7 @@ fi dnl Enable polar mode gridded surface plots AC_ARG_ENABLE(polar-grid,dnl -[ --enable-polar-grid include support for gridded polar surface plots], +[ --enable-polar-grid include support for gridded polar surface plots], [if test "$enableval" != no; then AC_DEFINE(USE_POLAR_GRID,1, [ Define to support polar gridded surface plots]) @@ -1240,25 +1240,26 @@ AC_MSG_RESULT([gnuplot will be compiled with the following terminals:]) AC_MSG_RESULT([]) AC_MSG_RESULT([ Standalone terminals: yes (included by default)]) -AC_MSG_RESULT([ canvas, cgm, context, dumb, dxf, emf, epslatex,]) -AC_MSG_RESULT([ fig, hpgl, pcl5, postscript,]) -AC_MSG_RESULT([ pict2e, pslatex, pstex, pstricks, svg, texdraw, tkcanvas]) +AC_MSG_RESULT([ canvas cgm context dumb dxf emf epslatex]) +AC_MSG_RESULT([ fig hpgl pcl5 postscript]) +AC_MSG_RESULT([ pict2e pslatex pstex pstricks svg texdraw tkcanvas]) AC_MSG_RESULT([]) if test "$with_bitmap_terminals" = yes; then - AC_MSG_RESULT([ dot-matrix terminals: yes ( --without-bitmap-terminals to disable)]) + AC_MSG_RESULT([ Dot-matrix terminals: yes ( --without-bitmap-terminals to disable)]) else - AC_MSG_RESULT([ dot-matrix terminals: no (use --with-bitmap-terminals to enable)]) + AC_MSG_RESULT([ Dot-matrix terminals: no (use --with-bitmap-terminals to enable)]) + AC_MSG_RESULT([ These would include, if enabled]) fi -AC_MSG_RESULT([ printers: epson, nec, okidata, tandy, seiko dpu414 ]) -AC_MSG_RESULT([ hp500c, hpdj, hpljii, hppj, starc]) +AC_MSG_RESULT([ printers: epson nec okidata tandy seiko dpu414 ]) +AC_MSG_RESULT([ hp500c hpdj hpljii hppj starc]) AC_MSG_RESULT([ other: block pbm ]) AC_MSG_RESULT([]) if test "$with_tektronix" = no; then - AC_MSG_RESULT([ tektronix terminal emulators: no ( --with-tektronix to enable)]) + AC_MSG_RESULT([ Tektronix terminal emulators: no ( --with-tektronix to enable)]) else - AC_MSG_RESULT([ tektronix terminal emulators: yes ( --without-tektronix to disable)]) + AC_MSG_RESULT([ Tektronix terminal emulators: yes ( --without-tektronix to disable)]) fi AC_MSG_RESULT([ tek410x tek40 vttek xterm kc_tek40 km_tek40 selanar bitgraph]) AC_MSG_RESULT([ sixeltek (not needed for sixel graphics output to vt100-series emulators)]) @@ -1336,91 +1337,79 @@ dnl These are the most common interactive terminal options AC_MSG_RESULT([]) if test "$no_x" != yes; then if test "$enable_x11_mbfonts" = yes; then - AC_MSG_RESULT([ x11 (X Window System) : yes (multi-byte fonts OK)]) + AC_MSG_RESULT([ x11 (X Window System): yes (multi-byte fonts OK)]) else - AC_MSG_RESULT([ x11 (X Window System) : yes (multi-byte fonts not supported)]) + AC_MSG_RESULT([ x11 (X Window System): yes (multi-byte fonts not supported)]) fi if test "$enable_x11_external" = yes; then - AC_MSG_RESULT([ (enable plotting to windows opened by external apps) ]) + AC_MSG_RESULT([ (enable plotting to windows opened by external apps) ]) else - AC_MSG_RESULT([ (disable plotting to windows opened by external apps) ]) + AC_MSG_RESULT([ (disable plotting to windows opened by external apps) ]) fi if test "$with_x_dcop" = yes; then AC_MSG_RESULT([ (gnuplot_x11 can use KDE3/DCOP to raise konsole) ]) fi else - AC_MSG_RESULT([ x11 (X Window System) : no (requires X libraries)]) + AC_MSG_RESULT([ x11 (X Window System) : no (requires X libraries)]) fi if test "$ac_cv_lib_gd_gdImageJpeg" = yes && test "$ac_cv_lib_gd_gdImagePng" = yes && test "$ac_cv_lib_gd_gdImageGif" = yes; then if test "$ac_cv_lib_gd_gdImageGifAnimBegin" = yes; then - AC_MSG_RESULT([ libgd-based png, jpeg, gif, and sixel terminals: yes (with animated gif)]) + AC_MSG_RESULT([ libgd-based png jpeg gif sixel: yes (with animated gif)]) else - AC_MSG_RESULT([ libgd-based png, jpeg, gif, and sixel terminals: yes (no animated gif)]) + AC_MSG_RESULT([ libgd-based png jpeg gif sixel: yes (no animated gif)]) fi else - AC_MSG_RESULT([ libgd-based png, jpeg, gif, and sixel terminals: no (requires libgd, see config.log) ]) + AC_MSG_RESULT([ libgd-based png jpeg gif sixel: no (requires libgd, see config.log) ]) fi if test "$with_cairo" = yes; then - AC_MSG_RESULT([ cairo-based pdf and png terminals: yes ]) + AC_MSG_RESULT([ cairo-based pdf png : yes ]) else AC_MSG_RESULT([ cairo-based terminals: no (requires cairo>=1.2, pango>=1.22, glib>=2.28)]) fi if test "$with_webp" = yes; then - AC_MSG_RESULT([ webp terminal: yes ]) + AC_MSG_RESULT([ webp : yes ]) else - AC_MSG_RESULT([ webp terminal: no (requires cairo, pango, libwebp, libwebpmux)]) + AC_MSG_RESULT([ webp : no (requires cairo, pango, libwebp, libwebpmux)]) fi if test "$with_lua" = yes; then - AC_MSG_RESULT([ lua/TikZ terminal: yes ]) + AC_MSG_RESULT([ lua/TikZ : yes ]) else - AC_MSG_RESULT([ lua/TikZ terminal: no ]) + AC_MSG_RESULT([ lua/TikZ : no ]) fi if test "$enable_wxwidgets_ok" = yes; then if test "$with_wx_multithreaded" = yes; then - AC_MSG_RESULT([ wxt terminal: yes (multithreaded)]) + AC_MSG_RESULT([ wxt : yes (multithreaded)]) else - AC_MSG_RESULT([ wxt terminal: yes ]) + AC_MSG_RESULT([ wxt : yes ]) fi else - AC_MSG_RESULT([ wxt terminal: no (requires C++, wxWidgets>2.6, cairo>0.9, pango>1.22)]) + AC_MSG_RESULT([ wxt : no (requires C++, wxWidgets>2.6, cairo>0.9, pango>1.22)]) fi if test "$enable_qt_ok" = yes; then if test "$QTVER" = 4; then - AC_MSG_RESULT([ Qt terminal: yes (qt4)]) + AC_MSG_RESULT([ Qt : yes (qt4)]) fi if test "$QTVER" = 5; then - AC_MSG_RESULT([ Qt terminal: yes (qt5)]) + AC_MSG_RESULT([ Qt : yes (qt5)]) fi else - AC_MSG_RESULT([ Qt terminal: no (use --with-qt or --with-qt=qt4 to enable]) + AC_MSG_RESULT([ Qt : no (use --with-qt or --with-qt=qt4 to enable]) fi AC_MSG_RESULT([]) AC_MSG_RESULT([gnuplot will be compiled with the following configurable features:]) AC_MSG_RESULT([]) -if test "$enable_mouse" = yes; then - AC_MSG_RESULT([ Mouse support in interactive terminals: yes]) -else - AC_MSG_RESULT([ Mouse support in interactive terminals: no]) -fi - -if test "$enable_raise_console" = yes; then - AC_MSG_RESULT([ Typing in plot window raises console: yes]) -else - AC_MSG_RESULT([ Typing in plot window raises console: no]) -fi - if test "$with_readline" = no; then AC_MSG_RESULT([ No readline support (use --with-readline=gnu or --with-readline=builtin)]) fi @@ -1447,15 +1436,27 @@ fi fi if test "$enable_history_file" = yes; then - AC_MSG_RESULT([ Command-line history file: yes]) + AC_MSG_RESULT([ Command-line history file: yes]) else - AC_MSG_RESULT([ Command-line history file: no]) + AC_MSG_RESULT([ Command-line history file: no]) fi if test "$with_row_help" = no; then - AC_MSG_RESULT([ Sort help/subtopic tables by column: yes]) + AC_MSG_RESULT([ Sort help tables by column rather than row: yes]) +else + AC_MSG_RESULT([ Sort help tables by column rather than row: no]) +fi + +if test "$enable_mouse" = yes; then + AC_MSG_RESULT([ Mouse support in interactive terminals: yes]) +else + AC_MSG_RESULT([ Mouse support in interactive terminals: no]) +fi + +if test "$enable_raise_console" = yes; then + AC_MSG_RESULT([ Typing in plot window raises console: yes]) else - AC_MSG_RESULT([ Sort help/subtopic tables by column: no (use --without-row-help to enable)]) + AC_MSG_RESULT([ Typing in plot window raises console: no]) fi if test "$have_libcerf" = yes; then @@ -1465,20 +1466,20 @@ else fi if test "$have_amoslibrary" = yes; then - AC_MSG_RESULT([ Airy and Bessel functions from libopenspecfun or libamos: yes]) + AC_MSG_RESULT([ Complex Airy and Bessel functions: yes]) else - AC_MSG_RESULT([ Library containing Amos routines for complex functions not found]) + AC_MSG_RESULT([ Complex Airy and Bessel functions: no (requires libopenspec or libamos]) fi if test "$have_cexint" = yes; then - AC_MSG_RESULT([ Complex exponential integral cexint from libamos: yes]) + AC_MSG_RESULT([ Complex exponential integral cexint (libamos): yes]) else - AC_MSG_RESULT([ Complex exponential integral cexint from libamos: no]) + AC_MSG_RESULT([ Complex exponential integral cexint (libamos): no]) fi if test "$have_external_functions" = yes; then - AC_MSG_RESULT([ plugin support for loading external functions: yes ]) + AC_MSG_RESULT([ plugin support for loading external functions: yes ]) else - AC_MSG_RESULT([ plugin support for loading external functions: no ]) + AC_MSG_RESULT([ plugin support for loading external functions: no ]) fi dnl if test "$enable_backwards_compatibility" = yes; then @@ -1488,27 +1489,27 @@ dnl AC_MSG_RESULT([ Allow deprecated syntax: no (use --enable-backwards-compa dnl fi if test "$enable_stats" != no; then - AC_MSG_RESULT([ Statistical summary of data ("stats" command): yes]) + AC_MSG_RESULT([ Statistical summary of data ("stats" command): yes]) else - AC_MSG_RESULT([ Statistical summary of data ("stats" command): no (--enable-stats to enable)]) + AC_MSG_RESULT([ Statistical summary of data ("stats" command): no (--enable-stats to enable)]) fi if test "$enable_watchpoints" != no; then - AC_MSG_RESULT([ Support watchpoints during 2D plotting: yes]) + AC_MSG_RESULT([ Support watchpoints during 2D plotting: yes]) else - AC_MSG_RESULT([ Support watchpoints during 2D plotting: no (--enable-watchpoints to enable)]) + AC_MSG_RESULT([ Support watchpoints during 2D plotting: no (--enable-watchpoints to enable)]) fi if test "$enable_polar_grid" != no; then - AC_MSG_RESULT([ Support for polar gridded surfaces: yes]) + AC_MSG_RESULT([ Support for polar gridded surfaces: yes]) else - AC_MSG_RESULT([ Support for polar gridded surfaces: no (--enable-polar-grid to enable)]) + AC_MSG_RESULT([ Support for polar gridded surfaces: no (--enable-polar-grid to enable)]) fi if test "$enable_function_blocks" = yes; then - AC_MSG_RESULT([ Support function blocks: yes]) + AC_MSG_RESULT([ Support function blocks: yes]) else - AC_MSG_RESULT([ Support function blocks: no (--enable-function-blocks to enable)]) + AC_MSG_RESULT([ Support function blocks: no (--enable-function-blocks to enable)]) fi From 3e5edcf1bc751c6f77de1d744ebafd75039be946 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Sat, 21 Jan 2023 13:51:53 -0800 Subject: [PATCH 015/192] Don't use C++ style comments in C code --- src/bitmap.c | 12 ++++++------ src/plot.c | 2 +- term/dumb.trm | 24 ++++++++++++------------ term/tek.trm | 13 ++++++------- term/x11.trm | 35 +++++++++++++++++++---------------- 5 files changed, 44 insertions(+), 42 deletions(-) diff --git a/src/bitmap.c b/src/bitmap.c index c0827cb39..cf1df10c1 100644 --- a/src/bitmap.c +++ b/src/bitmap.c @@ -1029,7 +1029,7 @@ b_wline(unsigned int x1, unsigned int y1, unsigned int x2, unsigned int y2) } for (i = 1; i <= wh; i++) { x = xplot - wh2; - // for (x = (int) xplot - (int) wh2; dx <= ((int) xplot - (int) wh2 + wh); x++) + /* for (x = (int) xplot - (int) wh2; dx <= ((int) xplot - (int) wh2 + wh); x++) */ b_setpixel(x, yplot - wh2 + i, b_value); } } @@ -1044,7 +1044,7 @@ b_wline(unsigned int x1, unsigned int y1, unsigned int x2, unsigned int y2) } for (i = 1; i <= wh; i++) { x = xplot - wh2; - // for (x = (int) xplot - (int) wh2; dx <= ((int) xplot - (int) wh2 + wh); x++) + /* for (x = (int) xplot - (int) wh2; dx <= ((int) xplot - (int) wh2 + wh); x++) */ b_setpixel(x, yplot - wh2 + i, b_value); } } @@ -1256,7 +1256,7 @@ b_boxfill( switch (style & 0xf) { case FS_TRANSPARENT_SOLID: transparent = TRUE; - // fall-through + /* fall-through */ case FS_SOLID: /* use halftone fill pattern according to filldensity */ /* filldensity is from 0..100 percent */ @@ -1270,7 +1270,7 @@ b_boxfill( break; case FS_TRANSPARENT_PATTERN: transparent = TRUE; - // fall-through + /* fall-through */ case FS_PATTERN: /* use fill pattern according to fillpattern */ idx = (style >> 4); /* fillpattern is enumerated */ @@ -1323,7 +1323,7 @@ b_filled_polygon(int points, gpiPoint *corners) switch (style & 0xf) { case FS_TRANSPARENT_SOLID: transparent = TRUE; - // fall-through + /* fall-through */ case FS_SOLID: /* use halftone fill pattern according to filldensity */ /* filldensity is from 0..100 percent */ @@ -1335,7 +1335,7 @@ b_filled_polygon(int points, gpiPoint *corners) break; case FS_TRANSPARENT_PATTERN: transparent = TRUE; - // fall-through + /* fall-through */ case FS_PATTERN: /* use fill pattern according to fillpattern */ idx = GPMAX((style >> 4), 0); /* fillpattern is enumerated */ diff --git a/src/plot.c b/src/plot.c index 5ff7273d3..636d00d57 100644 --- a/src/plot.c +++ b/src/plot.c @@ -77,7 +77,7 @@ extern smg$create_key_table(); # include # include "win/winmain.h" # include "win/wcommon.h" -# include // for isatty +# include /* for isatty */ #endif /* _WIN32 */ /* GNU readline diff --git a/term/dumb.trm b/term/dumb.trm index 883db9439..a9369f5bf 100644 --- a/term/dumb.trm +++ b/term/dumb.trm @@ -327,7 +327,7 @@ DUMB_options() static TBOOLEAN is_wide_char(unsigned char *charpixel) { - // see also mbwidth() in readline.c + /* see also mbwidth() in readline.c */ if (encoding == S_ENC_UTF8) return (*charpixel >= 0xe3); else @@ -344,12 +344,12 @@ dumb_set_pixel(int x, int y, int v) && (unsigned int) y <= dumb_ymax) { charpixel = (unsigned char *)(&DUMB_PIXEL(x, y)); if (*charpixel == NUL && (x > 0)) { - // Also clear the wide character to the left + /* Also clear the wide character to the left */ unsigned char * c = (unsigned char *) &(DUMB_PIXEL((x - 1), y)); DUMB_PIXEL((x - 1), y) = 0; *c = ' '; } else if (is_wide_char(charpixel) && ((x + 1) <= dumb_xmax)) { - // This is a wide character, clear the cell to the right. + /* This is a wide character, clear the cell to the right. */ char * c = (char *) &(DUMB_PIXEL((x + 1), y)); DUMB_PIXEL((x + 1), y) = 0; *c = ' '; @@ -451,14 +451,14 @@ static unsigned to_ansi256(rgb255_color *c) { if ((c->r - 8) / 10 == (c->b - 8) / 10 && (c->r - 8) / 10 == (c->g - 8) / 10) { - // gray scale - if (c->g < 8) // black + /* gray scale */ + if (c->g < 8) /* black */ return 16; - if (c->g >= 238) // white + if (c->g >= 238) /* white */ return 231; - return (c->g - 8) / 10 + 232; // like XTerm, Mintty + return (c->g - 8) / 10 + 232; /* like XTerm, Mintty */ } else { - // 6x6x6 color cube + /* 6x6x6 color cube */ #define RMAPCUBE6(n) ((n >= 55) ? ((n) - 35) / 40 : 0) return (((unsigned) RMAPCUBE6(c->r) * 36) + ((unsigned) RMAPCUBE6(c->g) * 6) + @@ -816,7 +816,7 @@ DUMB_put_text(unsigned int x, unsigned int y, const char *str) if (dumb_text_attributes) dumb_attributes[dumb_xmax * y + x] = dumb_attr; if (is_wide_char((unsigned char *)(&DUMB_PIXEL(x, y))) && (x + 1) < dumb_xmax) { - DUMB_PIXEL(x + 1, y) = 0; // mark as occupied + DUMB_PIXEL(x + 1, y) = 0; /* mark as occupied */ x++; } } @@ -926,7 +926,7 @@ ENHdumb_OPEN( /* widthflag FALSE means do not update text position after printing */ ENHdumb_widthflag = widthflag; /* Many drivers will need to do something about font selection here */ - DUMB_set_font(fontname); // we ignore the font size + DUMB_set_font(fontname); /* we ignore the font size */ } } @@ -1028,14 +1028,14 @@ ENHdumb_put_text(unsigned int x, unsigned int y, const char *str) TERM_PUBLIC int DUMB_set_font(const char *s) { - // reset current attributes + /* reset current attributes */ if (dumb_text_attributes) memset(&dumb_attr, 0, sizeof(text_attr)); if (s == NULL || *s == NUL || !dumb_text_attributes) return TRUE; - // test for attributes + /* test for attributes */ if ((strstr(s, ":Bold") != NULL)) dumb_attr.bold = 1; if ((strstr(s, ":Italic") != NULL)) diff --git a/term/tek.trm b/term/tek.trm index fa38a714c..67dc7f4cf 100644 --- a/term/tek.trm +++ b/term/tek.trm @@ -510,9 +510,9 @@ static void SIXEL_setfont(void); /* This is the _maximum_ number of allowed palette entries. */ #define SIXEL_NCOL 256 -static int SIXEL_mode = 1; // mono=0, color=1 -static int SIXEL_font = 1; // small=1,medium=2,large=3 -static int SIXEL_ncol = 16; // actual number of colors to be used +static int SIXEL_mode = 1; /* mono=0, color=1 */ +static int SIXEL_font = 1; /* small=1,medium=2,large=3 */ +static int SIXEL_ncol = 16; /* actual number of colors to be used */ static int SIXEL_lt; static int SIXEL_fp, SIXEL_np; @@ -618,7 +618,7 @@ SIXEL_options() break; case SIXEL_COLOR: SIXEL_mode = 1; - // We do not change number of colors here. + /* We do not change number of colors here. */ term->flags &= ~TERM_MONOCHROME; c_token++; break; @@ -725,7 +725,7 @@ SIXEL_text() map = gp_alloc(6 * b_xsize * sizeof(unsigned), "sixeltek"); for (j = b_ysize - 6; j >= 0; j -= 6) { - // get pixel values only once + /* get pixel values only once */ for (i = 0; i < b_xsize; i++) for (l = 0; l < 6; l++) map[i * 6 + l] = b_getpixel(i, j + l); @@ -759,7 +759,7 @@ SIXEL_text() } else { for (l = 1; l <= n; l++) fputc(pc, gpoutfile); - no += n; + no += n; } if (i == b_xsize-1 && c != pc) { fputc(c, gpoutfile); @@ -887,7 +887,6 @@ SIXEL_make_palette(t_sm_palette *palette) if (SIXEL_fp > 0) { for (i = SIXEL_fp; i < SIXEL_ncol; i++) SIXEL_palette[i].state = SIXEL_COL_UNDEFINED; - // return SIXEL_np; } SIXEL_np = SIXEL_ncol; diff --git a/term/x11.trm b/term/x11.trm index 05fc97fc5..3e9cf9a2a 100644 --- a/term/x11.trm +++ b/term/x11.trm @@ -902,7 +902,7 @@ X11_waitforinput(int options) return getc(stdin); #else - // normal path + /* normal path */ fd_set fds; static struct gp_event_t ge; static int l = 0; @@ -915,16 +915,18 @@ X11_waitforinput(int options) if (ipc_back_fd < 0) { if (paused_for_mouse) { - // We're waiting for a command from the back-channel IPC, but this pipe - // doesn't exist, so we'll never get the command we're waiting for. Give - // up. + /* We're waiting for a command from the back-channel IPC, but this pipe + * doesn't exist, so we'll never get the command we're waiting for. + * Give up. + */ paused_for_mouse = 0; int_error(NO_CARET,"Mousing not active"); } if (options & TERM_WAIT_FOR_FONTPROPS) { - // Similar. No back-channel, so we'll never get the "done" event. - // Here I just silently return + /* Similar. No back-channel, so we'll never get the "done" event. + * Here I just silently return. + */ return 0; } return getc(stdin); @@ -935,11 +937,12 @@ X11_waitforinput(int options) * as on some systems /dev/null is not selectable. * TODO: should we close the ipc_back_fd in this case ? */ - // While we have ipc_back_fd data to process, process it. If not, read the - // stdin data + /* While we have ipc_back_fd data to process, process it. + * If not, read the stdin data. + */ do { int ierr; - struct timeval *timeout = NULL; // wait forever by default + struct timeval *timeout = NULL; /* wait forever by default */ FD_ZERO(&fds); FD_SET(ipc_back_fd, &fds); @@ -962,21 +965,21 @@ X11_waitforinput(int options) } if (!FD_ISSET(ipc_back_fd, &fds)) { - // no ipc_back_fd data available. I can move on + /* no ipc_back_fd data available. I can move on */ if (options & TERM_ONLY_CHECK_MOUSING) return 0; if (blocking_loop_reading_ipc_back_fd) - // This shouldn't happen. In this case we should be waiting - // for ipc_back_fd data forever, so select() should never - // return with no data. In any case, I ask for more data if - // there isn't any + /* This shouldn't happen. In this case we should be waiting + * for ipc_back_fd data forever, so select() should never + * return with no data. In any case, I ask for more data if + * there isn't any. + */ continue; break; } - // got some ipc_back_fd data. Process all of it before moving on to - // stdin + /* got some ipc_back_fd data. Process all of it before moving on to stdin */ have_any_ipc_back_fd_data = true; n = read(ipc_back_fd, (void *) (l + (char *) &ge), sizeof(ge) - l); From c17ae98f586f64f88be311b3a9dd6d585b93987d Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Sat, 21 Jan 2023 14:53:30 -0800 Subject: [PATCH 016/192] initialize point array immediately upon allocation Otherwise UNDEFINED points may leave uninitialized holes in the coordinate structure, which valgrind flags as an error. --- src/plot2d.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/plot2d.c b/src/plot2d.c index aaee70338..335e3e8a8 100644 --- a/src/plot2d.c +++ b/src/plot2d.c @@ -126,12 +126,14 @@ cp_alloc(int num) struct lp_style_type default_lp_properties = DEFAULT_LP_STYLE_TYPE; cp = (struct curve_points *) gp_alloc(sizeof(struct curve_points), "curve"); - memset(cp,0,sizeof(struct curve_points)); + memset(cp, 0, sizeof(struct curve_points)); cp->p_max = (num >= 0 ? num : 0); - if (num > 0) + if (num > 0) { cp->points = (struct coordinate *) gp_alloc(num * sizeof(struct coordinate), "curve points"); + memset(cp->points, 0, num * sizeof(struct coordinate)); + } /* Initialize various fields */ cp->lp_properties = default_lp_properties; From 1ecf6bfb684bab4664f2e9dde887c11856e7f35a Mon Sep 17 00:00:00 2001 From: Tatsuro MATSUOKA Date: Sun, 22 Jan 2023 21:31:44 -0800 Subject: [PATCH 017/192] update INSTALL file for windows --- INSTALL | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/INSTALL b/INSTALL index 9e614b90c..01be79dc6 100644 --- a/INSTALL +++ b/INSTALL @@ -252,7 +252,7 @@ MS-Windows ---------- We provide binary packages with an installer or as "portable" versions packed -in zip / 7z format on SourceForge. +in 7z format on SourceForge. We currently support and test building with the following compilers and Makefiles: @@ -270,7 +270,7 @@ Some of the Makefiles include an "install" target (e.g. config/mingw/Makefile). In order to build the help file you require the "Microsoft HTML Help 1.4 SDK", which is freely downloadable here: -http://go.microsoft.com/fwlink/?LinkId=154968 +https://www.helpandmanual.com/downloads_mscomp.html MSDOS From 982a7db79ab323d8f1cd8bc0279753a4a83d0ae2 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Mon, 23 Jan 2023 17:17:26 -0800 Subject: [PATCH 018/192] bug in 2D key layout if both key->font and key->title.font are set If key->title.font is set, key->font was ignored during key layout. --- src/boundary.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/boundary.c b/src/boundary.c index 47a0fe0f8..bd2235f22 100644 --- a/src/boundary.c +++ b/src/boundary.c @@ -1014,10 +1014,10 @@ do_key_layout(legend_key *key) (void) estimate_strlen(key->title.text, &est_height); key_title_height = est_height * t->v_char; key_title_ypos = (key_title_height/2); - if (key->title.font) - t->set_font(""); /* FIXME: empirical tweak. I don't know why this is needed */ key_title_ypos -= (est_lines-1) * t->v_char/2; + if (key->title.font) + t->set_font((key->font) ? key->font : ""); } if (key->reverse) { From 536643bdb10edb5f22e67b7422514ed73dd237ac Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Mon, 23 Jan 2023 19:49:12 -0800 Subject: [PATCH 019/192] bug in 3D key layout if key->font is set The key font was totally ignored for the purpose of 3D key layout. Unlike the 2D case, this was true independent of key->title.font. --- src/graph3d.c | 30 ++++++++++++++++++++---------- 1 file changed, 20 insertions(+), 10 deletions(-) diff --git a/src/graph3d.c b/src/graph3d.c index 8ca5f3a4c..d68df2f23 100644 --- a/src/graph3d.c +++ b/src/graph3d.c @@ -72,6 +72,7 @@ static int key_title_extra; /* allow room for subscript/superscript */ static int key_title_width; static int key_width; static int key_height; +static int key_font_hchar; /* is contouring wanted ? */ t_contour_placement draw_contour = CONTOUR_NONE; @@ -334,13 +335,22 @@ boundary3d(struct surface_points *plots, int count) key_entry_height = t->v_char * key->vert_factor; } + /* string lengths for internal key layout (other than the title) + * use the key font. Save it for later use. + */ + if (key->font) + t->set_font(key->font); + key_font_hchar = t->h_char; + if (key->font) + t->set_font(""); + /* Approximate width of titles is used to determine number of rows, cols * The actual widths will be recalculated later */ max_ptitl_len = find_maxl_keys3d(plots, count, &ptitl_cnt); key_title_width = label_width(key->title.text, &i) * t->h_char; ktitle_lines = i; - key_col_wth = (max_ptitl_len + 4) * t->h_char + key_sample_width; + key_col_wth = (max_ptitl_len + 4) * key_font_hchar + key_sample_width; if (lmargin.scalex == screen) plot_bounds.xleft = lmargin.x * (double)t->xmax + 0.5; @@ -377,7 +387,7 @@ boundary3d(struct surface_points *plots, int count) if (ptitl_cnt > 0) { /* calculate max no cols, limited by label-length */ key_cols = (plot_bounds.xright - plot_bounds.xleft) - / ((max_ptitl_len + 4) * t->h_char + key_sample_width); + / ((max_ptitl_len + 4) * key_font_hchar + key_sample_width); if (key_cols == 0) key_cols = 1; key_rows = ((ptitl_cnt - 1)/ key_cols) + 1; @@ -4218,17 +4228,17 @@ do_3dkey_layout(legend_key *key, int *xinkey, int *yinkey) if (key->reverse) { key_sample_left = -key_sample_width; key_sample_right = 0; - key_text_left = t->h_char; - key_text_right = t->h_char * (max_ptitl_len + 1); - key_size_right = t->h_char * (max_ptitl_len + 2 + key->width_fix); - key_size_left = t->h_char + key_sample_width; + key_text_left = key_font_hchar; + key_text_right = key_font_hchar * (max_ptitl_len + 1); + key_size_right = key_font_hchar * (max_ptitl_len + 2 + key->width_fix); + key_size_left = key_font_hchar + key_sample_width; } else { key_sample_left = 0; key_sample_right = key_sample_width; - key_text_left = -(t->h_char * (max_ptitl_len + 1)); - key_text_right = -(t->h_char); - key_size_left = t->h_char * (max_ptitl_len + 2 + key->width_fix); - key_size_right = t->h_char + key_sample_width; + key_text_left = -(key_font_hchar * (max_ptitl_len + 1)); + key_text_right = -(key_font_hchar); + key_size_left = key_font_hchar * (max_ptitl_len + 2 + key->width_fix); + key_size_right = key_font_hchar + key_sample_width; } key_point_offset = (key_sample_left + key_sample_right) / 2; From b4583745cd6b9ad50f6f71b0e8a4894ec4354744 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Thu, 26 Jan 2023 15:28:17 -0800 Subject: [PATCH 020/192] Allow array declaration to initialize the array from an expression Example: array A = split("a b c d e") --- demo/array_index.dem | 2 ++ docs/gnuplot.doc | 10 ++++++---- src/command.c | 14 ++++++++++++++ 3 files changed, 22 insertions(+), 4 deletions(-) diff --git a/demo/array_index.dem b/demo/array_index.dem index 1edca8e3c..fc7cdd803 100644 --- a/demo/array_index.dem +++ b/demo/array_index.dem @@ -5,6 +5,7 @@ # It returns the index of that entry. array A = [1, 2, 3.0, 4.0, "five", "six", 7*I, {8,8}, NaN] +array B = A[2:4] do for [ i = 1:|A| ] { x = A[i] @@ -15,6 +16,7 @@ do for [ i = 1:|A| ] { print "no member of A matches ", x } } +print "array B = ", B # Use of index to establish key/value pairs print "\nKey/value pairs\n" diff --git a/docs/gnuplot.doc b/docs/gnuplot.doc index 252a164ca..4f01df2ea 100644 --- a/docs/gnuplot.doc +++ b/docs/gnuplot.doc @@ -3223,8 +3223,9 @@ C ... and restart the table: Arrays are implemented as indexed lists of user variables. The elements in an array are not limited to a single type of variable. Arrays must be created explicitly before being referenced. The size of an array cannot be changed - after creation. All elements are initially undefined. In most places an array - element can be used instead of a named user variable. + after creation. Array elements are initially undefined unless they are + provided in the array declaragion. + In most places an array element can be used instead of a named user variable. The cardinality (number of elements) of array A is given by the expression |A|. @@ -3236,6 +3237,7 @@ C ... and restart the table: A[4] = "four" A[6] = A[2]**3 array B[6] = [ 1, 2.0, A[3], "four", , B[2]**3 ] + array C = split("A B C D E F") do for [i=1:6] { print A[i], B[i] } 1 1 @@ -3246,8 +3248,8 @@ C ... and restart the table: 8.0 8.0 Note: Arrays and variables share the same namespace. For example, assignment - of a string variable named FOO will destroy any previously created array with - name FOO. + of a string to a variable named FOO will destroy any previously created array + with name FOO. The name of an array can be used in a `plot`, `splot`, `fit`, or `stats` command. This is equivalent to providing a file in which column 1 holds the diff --git a/src/command.c b/src/command.c index 4789e0aeb..85308f656 100644 --- a/src/command.c +++ b/src/command.c @@ -850,6 +850,7 @@ lower_command(void) * Arrays are declared using the syntax * array A[size] { = [ element, element, ... ] } * array A = [ .., .. ] + * array A = (only valid if returns an array) * where size is an integer and space is reserved for elements A[1] through A[size] * The size itself is stored in A[0].v.int_val.A * The list of initial values is optional. @@ -889,7 +890,20 @@ array_command() break; } nsize = est_size; + } else if (equals(c_token, "=")) { + /* array A = */ + struct value a; + int save_token = ++c_token; + const_express(&a); + if (a.type != ARRAY) { + free_value(&a); + int_error(save_token, "not an array expression"); + } + make_array_permanent(&a); + array->udv_value = a; + return; } + if (nsize > 0) init_array(array, nsize); else From 3abebfd14b9a50b86a3334542dccefe539a4240a Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Sat, 28 Jan 2023 21:14:04 -0800 Subject: [PATCH 021/192] Sanity check - very few smooth options work with polar coords Anything other than "smooth path" is an error --- docs/gnuplot.doc | 7 ++++--- src/plot2d.c | 11 +++++++++++ 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/docs/gnuplot.doc b/docs/gnuplot.doc index 4f01df2ea..9fe313b8b 100644 --- a/docs/gnuplot.doc +++ b/docs/gnuplot.doc @@ -7900,8 +7900,8 @@ Ffigure_zerror ## reread later and therefore it should be retained internally for re-use. #end - `splot` has a similar syntax but does not support `bins` and smoothing - support is limited to `smooth csplines` and `smooth acsplines`. + `splot` has a similar syntax but does not support `bins` and supports only a + few `smooth` options. The `noautoscale` keyword means that the points making up this plot will be ignored when automatically determining axis range limits. @@ -8359,7 +8359,8 @@ Ffigure_convex_hull If too few points are available to apply the requested smoothing operation an error message is produced. - The `smooth` options have no effect on function plots. + The `smooth` options have no effect on function plots. Only `smooth path` + is possible in polar coordinate mode. Smoothing in 3D plots (splot) is currently limited to generating a natural cubic spline to pass through a set of 3D points. In the general case diff --git a/src/plot2d.c b/src/plot2d.c index 335e3e8a8..2aad143dd 100644 --- a/src/plot2d.c +++ b/src/plot2d.c @@ -2520,6 +2520,17 @@ eval_plots() if (this_plot->plot_smooth == SMOOTH_PATH) parse_hull_options(this_plot); + /* Sanity check - very few smooth options work with polar coords */ + if (polar) { + switch(this_plot->plot_smooth) { + default: + int_error(c_token, "this smooth option not possible with polar coordinates"); + case SMOOTH_NONE: + case SMOOTH_PATH: + break; + } + } + if (set_smooth) duplication = TRUE; else From 74f4b827571706457390d8ef90951b535624bf30 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Mon, 30 Jan 2023 16:06:55 -0800 Subject: [PATCH 022/192] web docs: Create top-level files as symlinks I.e. Overview.html -> loc1.html Plotting_styles.html -> loc4508.html or wherever it ends up being. In particular this allows cross-references to the top level page for plotting styles, as in "See `plotting styles`.". --- docs/doc2web.c | 21 ++++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/docs/doc2web.c b/docs/doc2web.c index 9f37e5702..564169444 100644 --- a/docs/doc2web.c +++ b/docs/doc2web.c @@ -482,10 +482,7 @@ process_line(char *line, FILE *b, FILE *d) tabl = FALSE; /* output unique ID */ - if (startpage) { - strcpy(location, sectionname); - } else - sprintf(location, "loc%d", line_count); + sprintf(location, "loc%d", line_count); /* add list of subtopics */ if (!collapsing_terminal_docs && !processing_title_page) { @@ -538,7 +535,21 @@ process_line(char *line, FILE *b, FILE *d) exit(EXIT_FAILURE); } if (startpage) { - // fprintf(stderr,"Opening %s for output\n",newfile); + /* Make a symlink with a known name */ + char knownfile[PATH_MAX] = ""; + char locfile[16]; + strcpy(locfile, location); + strcat(locfile, ".html"); + strncpy(knownfile, path, PATH_MAX-1); + strncat(knownfile, sectionname, PATH_MAX-strlen(knownfile)-6); + strcat(knownfile,".html"); + if (symlink(locfile, knownfile)) { + perror("doc2web: Can't create symlink "); + exit(EXIT_FAILURE); + } + fprintf(stderr,"Creating symlink %s for %s\n", knownfile, newfile); + + /* Start the new file */ header(b, sectionname); #ifdef CREATE_INDEX sidebar(b, 1); From 8388e6c760395d2e284a90f9c590cc01e4612cf4 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Tue, 31 Jan 2023 14:52:45 -0800 Subject: [PATCH 023/192] incorrect fill area in parametric plot "with filledcurves y1=" Bug #1797 --- src/graphics.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/src/graphics.c b/src/graphics.c index 34615980c..f85542681 100644 --- a/src/graphics.c +++ b/src/graphics.c @@ -953,17 +953,20 @@ do_plot(struct curve_points *plots, int pcount) || this_plot->filledcurves_options.closeto == FILLEDCURVES_ABOVE || this_plot->filledcurves_options.closeto == FILLEDCURVES_BELOW) { plot_betweencurves(this_plot); - } else if (!this_plot->plot_smooth && + + } else if (!this_plot->plot_smooth && !parametric && (this_plot->filledcurves_options.closeto == FILLEDCURVES_ATY1 || this_plot->filledcurves_options.closeto == FILLEDCURVES_ATY2 || this_plot->filledcurves_options.closeto == FILLEDCURVES_ATR)) { - /* Smoothing may have trashed the original contents */ - /* of the 2nd y data column, so piggybacking on the */ - /* code for FILLEDCURVES_BETWEEN will not work. */ - /* FIXME: Maybe piggybacking is always a bad idea? */ - /* IIRC the original rationale was to get better clipping */ - /* but the general polygon clipping code should now work. */ + /* Smoothing may have trashed the original contents of the + * 2nd y data column, and parametric code never loaded it at all. + * Either way piggybacking on FILLEDCURVES_BETWEEN will not work. + * FIXME: Maybe piggybacking is always a bad idea? + * IIRC the original rationale was to get better clipping + * but the general polygon clipping code should now work. + */ plot_betweencurves(this_plot); + } else { plot_filledcurves(this_plot); } From b25f0cb49a265b0098817310f83b24d733100e62 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Tue, 31 Jan 2023 22:23:21 -0800 Subject: [PATCH 024/192] revise and update INSTALL --- INSTALL | 382 ++++++++++++++++++++++++-------------------------------- 1 file changed, 162 insertions(+), 220 deletions(-) diff --git a/INSTALL b/INSTALL index 01be79dc6..b8a6dd70f 100644 --- a/INSTALL +++ b/INSTALL @@ -2,16 +2,18 @@ Table of contents: ================== * Installation from sources + * Use of ./configure script to customize your build * More details about ./configure --with-PACKAGE[=OPTION] - * Platform compiler problems + * Inclusion of optional features --enable-FEATURE + * Platform-specific issues + linux OSX Windows MSDOS + OS/2 and WPS * Environment variables * How to test gnuplot - * Installing WPS object for gnuplot on OS/2 - * Compiling Gnuplot with the wxt (wxWidgets) terminal If you are installing a binary package, you may still want to check out -some sections of this document, particularly the one discussing -environment variables. +some sections of this document, particularly the sections at the end +about environment variables and testing gnuplot after installation. Installation from sources @@ -20,8 +22,8 @@ Installation from sources For the impatient ----------------- - Configuration options are in the Makefile and in src/term.h, which -selects the set of terminal drivers to be compiled in. + Configuration options are in the Makefile and in src/term.h, where you +select additional terminal drivers to be compiled in. The recommended way to configure both of these is the GNU-style "./configure" script described below and described further in INSTALL.gnu. @@ -56,7 +58,7 @@ terminal support files PREFIX/share/gnuplot/$VERSION/js The only files where the runtime location is defined at compile time are -gnuplot.gih and show.c. This is important if gnuplot is not installed +gnuplot.gih and show.c. This is important if gnuplot is not installed by running 'make install'. The default path for the help library, gnuplot.gih, can be controlled in @@ -85,7 +87,7 @@ several different ways: o at execution time by specifying the helpfile with the environment variable GNUHELP (see "Environment Variables" below). - The default location of the main executable can be controlled in + The default location of the main executable can be controlled in different ways: o with configure's --prefix= option, eg. @@ -101,7 +103,7 @@ different ways: make bindir='/gnuplot/bin' gnuplot will be installed as /gnuplot/bin/gnuplot. - The default location of the additional executable, like gnuplot_x11, + The default location of the additional executable, like gnuplot_x11, can be controlled in different ways: o with configure's --prefix= option, eg. @@ -126,8 +128,9 @@ platforms (but they still work as input scripts to gnuplot). there is no universally agreed place where such files should go. If desired, they should be copied manually to a location of choice. -Unix, configure ---------------- + +Use of ./configure script to customize your build +================================================= On Unix, use $ ./configure @@ -138,29 +141,30 @@ $ make install If gcc is installed, it is used by default. A different compiler can be used by passing its name to configure: -$ ./configure CC=c99 - - Any environment settings for CFLAGS are included into the Makefile, -so please make sure that these are really needed. - +$ ./configure CC=clang CXX=clang++ + + Any environment settings for CFLAGS and CXXFLAGS are included into the +Makefile, so please make sure that these are appropriate. Example: + +$ export CXXFLAGS="-Wall -g -Og -fPIC -std=c++11" + There are several options available for configure that you may want to change. A complete list of options is available through $ ./configure --help Many of the available options are generic to programs built with the - autotools/autoconf build system. - Some options specifically relevant to gnuplot are listed below: - - --disable-history-file do not use history file - --without-latex do not install latex support files - --with-textdir=DIR where to install latex support files - --without-tektronix do not include tektronix terminal emulators + autotools/autoconf build system. A few example options specifically + relevant to gnuplot are shown below: --with-readline={gnu|bsd|builtin} Override the automatic choice of terminal input modes. See below for more detail. + --disable-history-file do not use history file + --without-latex do not install latex support files + --with-textdir=DIR where to install latex support files + Source files for many older terminal types, legacy output modes, and hardware or platform-specific devices are included in the distribution. These can be included in the gnuplot executable by selecting a corresponding @@ -171,7 +175,6 @@ and also build in support for a large set of 1990s era dot matrix printers ./configure --with-tektronix --with-bitmap-terminals - Options marked with (*) are enabled by default, ie. these features or packages are used if configure detects them even if the corresponding option is not specified. Please note that the `--with-PACKAGE' @@ -183,22 +186,110 @@ options can have additional arguments: o `--with-PACKAGE=DIR' checks for PACKAGE in DIR +More details about ./configure --with-PACKAGE[=OPTION] +====================================================== + +Every `--with-PACKAGE' option sets a `with_package' variable in configure. +Depending on how `--with-PACKAGE' was invoked, there are only three different +possible values for the `with_package' variable: + + Option $with_package +---------------------------------------- +(not specified) yes or no; default set in configure +--with-package yes +--with-package=yes yes +--with-package=no no +--with-package=DIR DIR +--without-package no + +In gnuplot, the following --with-PACKAGE options are available. The +--with-PACKAGE=DIR form is always required if a package is installed in a +non-default location that is not searched by the preprocessor or linker. + + --with-readline + + Use whatever readline support is detected automatically, either an + external library or gnuplot's built-in version. This is the default. + + --with-readline=builtin + + Use gnuplot's own builtin readline routines even if a GNU or BSD readline + library is detected. + + --without-readline + + (same as --with-readline=no) Do not use any readline processing. + + --with-readline=gnu + + Use the GNU readline library instead of gnuplot's builtin readline. + + --with-readline[=DIR] + + Use the GNU readline library instead of gnuplot's builtin readline. + This form is required if GNU readline is not installed in a default + location. + + --with-gd[=DIR] + + Thomas Boutell's gd library is needed to support jpeg and gif output. + It is also one of several options for producing png or sixel output. + This option is on by default, i.e. configure will check if the library exists + and use it if found. + + --with-amos=DIR + --with-libcerf + + Gnuplot includes support for additional complex special functions provided + by one or more of the external libraries libcerf, libamos, or libopenspecfun. + The ./configure script will search for these in standard system library + locations and include support for the routines that are found. + These libraries are relatively uncommon, however, so you might want to + build them separately and tell the ./configure script where they are + using for example --with-amos=/usr/local/lib/ + If these libraries are not found, gnuplot will configure and build + successfully but it will not provide the corresponding special functions. + + +Inclusion of optional features +============================== + +Each release of gnuplot may include features that are experimental or of +limited general interest. These may be optionally included or excluded +from the configuration using the --enable or --disable flags. +Examples from gnuplot 6 include + + --enable-watchpoints support setting watchpoints in 2D plots + --enable-function-blocks support defining a function as a here document + +These features may become standard in a subsequent release and will then +no longer require a special configuration option. + + +Platform-specific issues +======================== + Linux ----- - ./configure may fail to find lua support if the package configuration tool is - installed as "lua5.1" or "lua5.3" rather than "lua". If necessary, you can fix - this by adding a symlink prior to running ./configure as shown below: + lua: ./configure may fail to find lua support if the package configuration + tool is installed as "lua5.1" or "lua5.3" rather than "lua". If necessary, + you can fix this by adding a symlink prior to running ./configure - ln -s /usr/lib/pkgconfig/lua5.3.pc /usr/lib/pkgconfig/lua.pc + ln -s /usr/lib/pkgconfig/lua5.3.pc /usr/lib/pkgconfig/lua.pc + wxt: Some wxWidgets configurations require linking to the X11 library but + fail to include "-lX11" in the string provided for auto-configuration. + You may have to add this manually when configuring gnuplot: + TERMLIBS="-lX11" ./configure + Note that some people have reported runtime problems with wxgtk 3.0. + If you have the option of linking to libraries for wxgtk 2.8 instead, + this may be preferable. The -lX11 flag is not need in this case. Mac OSX ------- -Readline issues: - - As I understand the situation, Apple ships OSX with a "fake" libreadline + Readline: As I understand the situation, OSX ships with a "fake" libreadline shared library. The file /usr/lib/libreadline.dylib is really a symlink to a compatibility layer over the BSD libedit library. But the compatibility isn't complete, and in particular it is missing some routines used for readline @@ -206,10 +297,10 @@ Readline issues: But you will still be left without some of the functionality of the "real" libreadline. For one thing, libedit doesn't handle UTF-8 input. You have several options: - + 1) Delete the fake libreadline libraries from OSX and install the real gnu libreadline as a system library. - + 2) Install the real gnu libreadline into your personal account and tell gnuplot to use it: ./configure --with-readline=/my/private/readline/installdir @@ -221,14 +312,12 @@ Readline issues: input and tab-completion of file names. ./configure --with-readline=builtin -wxt terminal: - - This interactive terminal is in principle cross-platform and you needn't - do anything special. However if you discover that practice diverges from - principle, the notes below that were collected from problems encountered - in the past might help. + wxt: This interactive terminal is in principle cross-platform and you + needn't do anything special. However if you discover that practice + diverges from principle, the notes below collected from problems + encountered in the past might help. - Cairo & pango need to be installed first on Mac, + Cairo & pango need to be installed first on Mac, I recommend using MacPorts building universal (i386 libraries): sudo port install cairo +no_x11 +quartz +universal sudo port install pango +no_x11 +quartz +universal @@ -240,19 +329,11 @@ wxt terminal: Carbon API on Mac which is 32-bit only, that makes compiling gnuplot, cairo and pango to i386 necessary. - linux: Some wxWidgets configurations require linking to the X11 library but - fail to include "-lX11" in the string provided for auto-configuration. - You may have to add this manually when configuring gnuplot: - TERMLIBS="-lX11" ./configure - Note that some people have reported runtime problems with wxgtk 3.0. - If you have the option of linking to libraries for wxgtk 2.8 instead, - this may be preferable. The -lX11 flag is not need in this case. - MS-Windows ---------- -We provide binary packages with an installer or as "portable" versions packed -in 7z format on SourceForge. +We provide binary packages on SourceForge, either as a self-installing +executable or as a "portable" version packed in 7z format. We currently support and test building with the following compilers and Makefiles: @@ -268,11 +349,10 @@ For MSYS2/Mingw-w64 you can find detailed instructions at https://sourceforge.net/p/gnuplot/support-requests/199/ Some of the Makefiles include an "install" target (e.g. config/mingw/Makefile). -In order to build the help file you require the "Microsoft HTML Help 1.4 -SDK", which is freely downloadable here: +In order to build the help file you require the "Microsoft HTML Help Workshop", +which is freely downloadable here: https://www.helpandmanual.com/downloads_mscomp.html - MSDOS ----- @@ -307,128 +387,41 @@ Be sure to enable only those devices for which you have the necessary software already installed. Also ensure that the libraries and the sources are all compiled (not) using the '-Zmt' flags. -Executing +Executing make -f makefile.os2 should create a default build while make -f makefile.os2 help will show you all pre-defined targets. -See other sections of the manuals for more information about installing/using -gnuplot on OS/2. +WPS object for gnuplot on OS/2 +------------------------------ +GNUPLOT can be run from the command line of an OS/2 session, or can be set up +as a program object in the WPS. -More details about ./configure --with-PACKAGE[=OPTION] -====================================================== - -Every `--with-PACKAGE' option sets a `with_package' variable in configure. -Depending on how `--with-PACKAGE' was invoked, there are only three different -possible values for the `with_package' variable: - - Option $with_package ----------------------------------------- -(not specified) yes or no; default set in configure ---with-package yes ---with-package=yes yes ---with-package=no no ---with-package=DIR DIR ---without-package no - -In gnuplot, the following --with-PACKAGE options are available. The ---with-PACKAGE=DIR form is always required if a package is installed in a -non-default location that is not searched by the preprocessor or linker. - - --with-readline - - Use whatever readline support is detected automatically, either an - external library or gnuplot's built-in version. This is the default. - - --with-readline=builtin - - Use gnuplot's own builtin readline routines even if a GNU or BSD readline - library is detected. - - --without-readline - - (same as --with-readline=no) Do not use any readline processing. - - --with-readline=gnu - - Use the GNU readline library instead of gnuplot's builtin readline. - - --with-readline[=DIR] +GNUPLOT starts up as a command line session which accepts the usual GNUPLOT +input. The Presentation Manager (PM) window for graphics display is only opened +when the first 'plot' or 'splot' command is entered. - Use the GNU readline library instead of gnuplot's builtin readline. - This form is required if GNU readline is not installed in a default - location. +If GNUPLOT is set up as a program object, it can be configured for 'drag and +drop' in the usual way, by specifying '%*' as the program parameter. - --with-gd[=DIR] +The PM window has facilities for printing the plot, for changing the fonts +used in the plot, and so on. These of course are handled through the usual +PM interface. In addition, you can 'drop' a font onto the window to change +the font. - Thomas Boutell's gd library is needed to support jpeg and gif output. - It is also one of several options for producing png output. - This option is on by default, i.e. configure will check if the library exists, - and use it if found. +The usual GNUPLOT commands can also be used to produce output on supported +devices. +Settings and the positions and sizes of the windows can be saved in the file +gnushell.ini. This file is saved in the program's working directory; several +different directories can be set up (as program objects) with different +options, if you wish. -Platform compiler problems -========================== - -This section addresses trouble shooting and testing issues. Userland questions -are answered in the FAQ. - -Platform and compiler notes (probably long out of date) -------------------------------------------------------- - - Generally, if you think that configure has made a mistake in detecting -platform features, you should consider that a bug either in GNU autoconf -or in gnuplot's use of it, which you should report. As a workaround -you can override such faulty tests in a site-wide collection -of preset configure test results, or manually override them after running -configure. - - Example: -configure was for some reason unable to detect the memset() function, but -you are sure it is ok to use on your platform. To fix that, you'll have -to edit the generated config.h and change the line - - /* #undef HAVE_MEMSET */ -to - #define HAVE_MEMSET 1 - - Note that changing such defines from outside config.h, eg. via -'make DEFS=-DHAVE_MEMSET' is wrong, because config.h will usually -override such changes. Also note that this change will be lost -whenever you re-run configure. - - - gcc -ansi - - If you wish to compile with gcc -ansi (CC='gcc -ansi -pedantic' - ./configure), additional platform specific defines may be necessary - to include non-ANSI function prototypes. E.g. on Solaris, - -D__EXTENSIONS__ is needed. Otherwise, non-declared functions not - returning int will be assumed to return int, with possibly - dangerous consequences. Especially scpecfun.c is vulnerable here. - - - HP-UX 10.x and above - GCC has known problems on this platform if configured to use HP's - assembler. The telltale symptom are tic labels all ending up at - position 0.0. So either make sure you use a GCC configured to use - GNU as, or use HP's ANSI cc (the unbundled one). - - - Alpha CPUs - The Alpha family of CPUs exhibits somewhat unusual behaviour in the - case of floating point exceptions. In default mode, it doesn't comply - to IEEE floating point standards very well, leading to crashes of the - whole program because of a floating point exception in certain cases. - In order to avoid these, you may want to turn on IEEE compatibility - mode in your compiler flags. For DEC cc, the relevant option is - `-ieee', for GCC, it's `-mieee'. The configure script tries to - automatically detect this situation and apply the flag, but you may want - to double-check it. - - - SunOS / Solaris - There are known issues with regard to compiler support for Booleans. - You may have to tweak gnuplot's definition of TBOOLEAN. - The plugin demo Makefile may also require editing as noted in comments. +PM terminal is fully mouse-capable. Type 'm' to switch the mouse on/off (see +'help mouse' for more details), or 'h' for the full list of current hotkeys +(see also 'help bind'). Environment variables @@ -459,20 +452,21 @@ On all versions of Windows and OS/2 the variable looked at is COMSPEC. Other platforms will consult SHELL. The x11 and qt terminals each require an auxiliary program (gnuplot_x11 -gnuplot_qt) to manage the displayed plots. These are installed by +gnuplot_qt) to manage the displayed plots. These are installed by default in /usr/local/libexec/gnuplot// but this default can be overridden by the environmental variable GNUPLOT_DRIVER_DIR. GDFONTPATH is the directory where the libgd terminals (jpeg png gif) -search for fonts. You should set it to directory where files like +search for fonts. You should set it to directory where files like arial.ttf and Symbol.pfa exist. GNUPLOT_DEFAULT_GDFONT is the default font to be used by the png and jpeg terminal types. This must either be a full path to the font file or the face name of a font found in the GDFONTPATH search path. - + GNUPLOT_FONTPATH is used by the postscript driver as search path for -postscript (Adobe Type 1 and Type 2) fonts. +postscript (Adobe Type 1 and Type 2) fonts (only needed if you want +to embed a copy of the font in the output file, which is not common). GNUPLOT_PS_DIR is used by the postscript driver to use external prologue files. Depending on the build process, gnuplot contains either a builtin @@ -548,55 +542,3 @@ gnuplot> test appropriate for the terminal you are using. -Installing WPS object for gnuplot on OS/2 -========================================= - -GNUPLOT can be run from the command line of an OS/2 session, or can be set up -as a program object in the WPS. - -GNUPLOT starts up as a command line session which accepts the usual GNUPLOT -input. The Presentation Manager (PM) window for graphics display is only opened -when the first 'plot' or 'splot' command is entered. - -If GNUPLOT is set up as a program object, it can be configured for 'drag and -drop' in the usual way, by specifying '%*' as the program parameter. - -The PM window has facilities for printing the plot, for changing the fonts -used in the plot, and so on. These of course are handled through the usual -PM interface. In addition, you can 'drop' a font onto the window to change -the font. - -The usual GNUPLOT commands can also be used to produce output on supported -devices. - -Settings and the positions and sizes of the windows can be saved in the file -gnushell.ini. This file is saved in the program's working directory; several -different directories can be set up (as program objects) with different -options, if you wish. - -PM terminal is fully mouse-capable. Type 'm' to switch the mouse on/off (see -'help mouse' for more details), or 'h' for the full list of current hotkeys -(see also 'help bind'). - - -Compiling Gnuplot with the wxWidgets terminal -============================================== - -The `wxt` terminal provides an interactive windowed output. The code is -cross-platform and can be compiled as soon as the following requirements are -met: - -First, this terminal is based on the wxWidgets library. This library can be -found on http://www.wxwidgets.org. It comes in different flavours corresponding -to the underlying API : Microsoft Windows ("wxMSW"), GTK+ ("wxGTK"), X11 -("wxX11"), MacOS ("wxMAC"), etc. - -Then, the terminal needs the Cairo library (no specific backend is required) -which can be found on http://www.cairographics.org, and the Pango library, -which can be found on http://www.pango.org and need to be compiled with its -Cairo backend. - -On Unix, use the usual `./configure; make; make install' build process to -compile this terminal. On Windows, please use the MinGW/MSYS makefile, namely -config/makefile.mgw. MinGW and MSYS can be found on http://www.mingw.org. - From 9564eee583a085c152e5002587ede1b4ac592f92 Mon Sep 17 00:00:00 2001 From: Vincent Lefevre Date: Fri, 13 Jan 2023 16:32:28 -0800 Subject: [PATCH 025/192] Remove spurious Texinfo comment from gnuplot.info The docs/doc2texi.el converter transforms the line starting with "<3" into a Texinfo comment by inserting "@c " at the beginning of the line (function d2t-get-terminals). However, the input has not been converted to the Texinfo format yet, so that function d2t-braces-atsigns, which is called later, assumes that "@c" is real text and adds a @ in front of it. As a consequence, one gets a line @@c <3 -- all terminal stuff is pulled from the .trm files in the generated Texinfo file gnuplot.texi, and this line will be rendered as @c <3 -- all terminal stuff is pulled from the .trm files in the Info manual. This patch makes doc2texi.el remove the "<3" line instead of attempting to comment it out. --- docs/doc2texi.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/doc2texi.el b/docs/doc2texi.el index 8dd66ef58..12c2a4392 100644 --- a/docs/doc2texi.el +++ b/docs/doc2texi.el @@ -479,8 +479,8 @@ the end of `d2t-get-terminals'.") (save-excursion (when (re-search-forward "^<3" (point-max) t) (beginning-of-line) - (insert "@c ") - (forward-line 1) + (let ((eol (save-excursion (end-of-line) (point-marker)))) + (delete-region (point-marker) eol)) (dolist (elem list) (and d2t-verbose (message " %s ..." elem)) (setq file (concat d2t-terminal-directory elem ".trm")) From 29d199c74981122d5f961b3218ef20edc1981805 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Thu, 26 Jan 2023 20:19:05 -0800 Subject: [PATCH 026/192] configure --with-gd=DIR takes precedence over pkgconfig Modify the order of searching for libgd so that a user-supplied DIR is tried first. The system's pkgconfig file gdlib.pc is only searched if no DIR is given. Use of a gdlib-config script has been deprecated upstream. No change to the operation of configure --with-gd configure --with-gd=yes configure --with-gd=no configure --without-gd Bug #2569 --- configure.ac | 28 ++++++++++------------------ 1 file changed, 10 insertions(+), 18 deletions(-) diff --git a/configure.ac b/configure.ac index 8d2bda12c..4de384f65 100644 --- a/configure.ac +++ b/configure.ac @@ -557,30 +557,22 @@ dnl check presence of gd library dnl we don't check for libfreetype and libjpeg locations - if gd requires dnl them, the gdlib-config script or the gdlibc.pc contains all the required information AC_ARG_WITH(gd,dnl -[ --with-gd[=DIR] location of gd library (png jpeg gif terminals)],, +[ --with-gd[=DIR] (DIR is location of include/gd.h and lib/libgd.so)],, with_gd=yes) -if test "$with_gd" != no; then - PKG_CHECK_MODULES_NOFAIL(libgd, [gdlib]) - AC_PATH_PROG([GDLIB_CONFIG], [gdlib-config]) +if test -d "$with_gd"; then + libgd_LDFLAGS=-L$with_gd/lib + libgd_CFLAGS=-I$with_gd/include + libgd_LIBS=-lgd + AC_MSG_WARN(([Looking for $with_gd/include/gd.h and $with_gd/lib/libgd.so])) +elif test "$with_gd" != no; then + PKG_CHECK_MODULES_NOFAIL(libgd, [gdlib]) # If pkg-config did return libgd configuration then # libgd_{CFLAGS,LDFLAGS,LIBS} is set - # If gdlib-config executable is found then GDLIB_CONFIG is set - if test $pkg_failed = no && test -n "$GDLIB_CONFIG"; then - # If pkg-config did succeed and we have gdlib-config then the later takes - # priority - libgd_CFLAGS=`$GDLIB_CONFIG --cflags` - libgd_LDFLAGS=`$GDLIB_CONFIG --ldflags` - libgd_LIBS=`$GDLIB_CONFIG --libs` - elif test -d "$with_gd"; then - # pkg-config did NOT succeed, we do NOT have gdlib-config but user - # specified --with-gd= - libgd_CFLAGS="-I$with_gd/include" - libgd_LDFLAGS="-L$with_gd/lib" - libgd_LIBS="-ljpeg -lpng -lfreetype -lz" - fi +fi +if test "$with_gd" != no; then # Verify that libgd works, but backup the previous compilation variables to # be able to revert in the case that libgd is not functional _cppflags="$CPPFLAGS" From 19415086ef6fd55ea0e54d90ec62a430eac22289 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Mon, 30 Jan 2023 14:16:42 -0800 Subject: [PATCH 027/192] remove configure option --with-row-help Make it a user option instead: set help {rows|columns} This is clearly a per-user preference, not something that should be a build-time option. Why would you expect all end users to have the same preference? --- config/config.cyg | 3 --- config/config.dj2 | 3 --- config/config.mgw | 3 --- config/config.nt | 3 --- config/config.os2 | 3 --- config/config.oww | 3 --- configure.ac | 15 --------------- configure.vms | 1 - src/help.c | 15 ++++++++------- src/help.h | 3 +++ src/set.c | 21 +++++++++++++++++++++ src/show.c | 15 +++++++++++++++ src/tables.c | 1 + src/tables.h | 2 +- 14 files changed, 49 insertions(+), 42 deletions(-) diff --git a/config/config.cyg b/config/config.cyg index 4be27065a..a917a2ada 100644 --- a/config/config.cyg +++ b/config/config.cyg @@ -7,9 +7,6 @@ /* Define to allow use of certain deprecated syntax. */ /* #undef BACKWARDS_COMPATIBLE */ -/* Define if you want online help and subtopic tables sorted by column. */ -/* #undef COLUMN_HELP */ - /* Provide contact info for gnuplot development */ #define DEVELOPMENT_VERSION 1 diff --git a/config/config.dj2 b/config/config.dj2 index c35ad5852..0f11cda47 100644 --- a/config/config.dj2 +++ b/config/config.dj2 @@ -7,9 +7,6 @@ /* Define to allow use of certain deprecated syntax. */ /* #undef BACKWARDS_COMPATIBLE */ -/* Define if you want online help and subtopic tables sorted by column. */ -/* #undef COLUMN_HELP */ - /* Provide contact info for gnuplot development */ /* #undef DEVELOPMENT_VERSION */ /* Don't change it here -- this define is set in config/djgpp/Makefile. */ diff --git a/config/config.mgw b/config/config.mgw index c3e3e2bd8..e0e1c382d 100644 --- a/config/config.mgw +++ b/config/config.mgw @@ -10,9 +10,6 @@ /* Define to allow use of certain deprecated syntax. */ /* #undef BACKWARDS_COMPATIBLE */ -/* Define if you want online help and subtopic tables sorted by column. */ -/* #undef COLUMN_HELP */ - /* Provide contact info for gnuplot development */ /* #undef DEVELOPMENT_VERSION */ /* Don't change it here -- this define is set in config/mingw/Makefile. */ diff --git a/config/config.nt b/config/config.nt index aa3855a37..ec272b9f0 100644 --- a/config/config.nt +++ b/config/config.nt @@ -8,9 +8,6 @@ /* Define to allow use of certain deprecated syntax. */ /* #undef BACKWARDS_COMPATIBLE */ -/* Define if you want online help and subtopic tables sorted by column. */ -/* #undef COLUMN_HELP */ - /* Provide contact info for gnuplot development */ /* #undef DEVELOPMENT_VERSION */ /* Don't change it here -- this define is set in config/msvc/Makefile. */ diff --git a/config/config.os2 b/config/config.os2 index 5aaed175e..b88582c16 100644 --- a/config/config.os2 +++ b/config/config.os2 @@ -7,9 +7,6 @@ /* Define to allow use of certain deprecated syntax. */ /* #undef BACKWARDS_COMPATIBLE */ -/* Define if you want online help and subtopic tables sorted by column. */ -/* #undef COLUMN_HELP */ - /* Provide contact info for gnuplot development */ /* #undef DEVELOPMENT_VERSION */ /* Don't change it here -- this define is set in config/makefile.os2 */ diff --git a/config/config.oww b/config/config.oww index 9d5e68044..23a978418 100644 --- a/config/config.oww +++ b/config/config.oww @@ -7,9 +7,6 @@ /* Define to allow use of certain deprecated syntax. */ /* #undef BACKWARDS_COMPATIBLE */ -/* Define if you want online help and subtopic tables sorted by column. */ -/* #undef COLUMN_HELP */ - /* Provide contact info for gnuplot development */ /* #undef DEVELOPMENT_VERSION */ /* Don't change it here -- this define is set in config/watcom/Makefile. */ diff --git a/configure.ac b/configure.ac index 4de384f65..0a29f0d97 100644 --- a/configure.ac +++ b/configure.ac @@ -741,15 +741,6 @@ if test "$with_extra_coordinate" != no; then [ Define to make use of otherwise empty space in struct coordinate ]) fi -dnl Sort help/subtopic tables by row or column -AC_ARG_WITH(row-help,dnl -[ --with-row-help format help and subtopic tables by row (default) - --without-row-help format help and subtopic tables by column], - [if test "$with_row_help" = no; then - AC_DEFINE(COLUMN_HELP,1, - [ Define if you want online help and subtopic tables sorted by column. ]) - fi]) - dnl Whether we want to create the LaTeX tutorial dnl TUTORIAL=notutorial dnl AC_ARG_WITH(tutorial,dnl @@ -1433,12 +1424,6 @@ else AC_MSG_RESULT([ Command-line history file: no]) fi -if test "$with_row_help" = no; then - AC_MSG_RESULT([ Sort help tables by column rather than row: yes]) -else - AC_MSG_RESULT([ Sort help tables by column rather than row: no]) -fi - if test "$enable_mouse" = yes; then AC_MSG_RESULT([ Mouse support in interactive terminals: yes]) else diff --git a/configure.vms b/configure.vms index ca66483be..0780f994b 100755 --- a/configure.vms +++ b/configure.vms @@ -330,7 +330,6 @@ $ HAVE_LIBPNG = 0 $ CGI = 0 $ NOCWDRC = 0 $ THIN_PLATE_SPLINES_GRID = 0 -$ COLUMN_HELP = 0 $ ! USE_MOUSE = 0 ! USE_MOUSE is defined above $ MAX_PARALLEL_AXES = 7 $ ! diff --git a/src/help.c b/src/help.c index c726db314..81cd6be2e 100644 --- a/src/help.c +++ b/src/help.c @@ -49,6 +49,9 @@ void OutLine(const char *M){fputs(M,stderr);} # include #endif +/* User control of help layout "set help {columns|rows}" */ +TBOOLEAN help_sort_by_rows = FALSE; + /* ** help -- help subsystem that understands defined keywords ** @@ -573,9 +576,8 @@ ShowSubtopics( * the next column is skipped */ #define COLLENGTH 18 -#ifndef COLUMN_HELP - { - /* sort subtopics by row - default */ +if (help_sort_by_rows) { + /* sort subtopics by row */ int subtopic; int spacelen = 0, ispacelen; int pos = 0; @@ -610,9 +612,9 @@ ShowSubtopics( (void) strcat(line, "\n"); OutLine_InternalPager(line); } - } -#else /* COLUMN_HELP */ - { + + } else { + /* sort subtopics by column */ int subtopic, sublen; int spacelen = 0, ispacelen; @@ -643,7 +645,6 @@ ShowSubtopics( OutLine_InternalPager(line); } } -#endif /* COLUMN_HELP */ if (subtopics) *subtopics = (subt != 0); diff --git a/src/help.h b/src/help.h index 18e194c44..14fd5d9df 100644 --- a/src/help.h +++ b/src/help.h @@ -41,6 +41,9 @@ #define H_NOTFOUND 1 /* didn't find the keyword */ #define H_ERROR (-1) /* didn't find the help file */ +/* User control of help layout */ +extern TBOOLEAN help_sort_by_rows; + /* Prototypes from file "help.c" */ int help(char *keyword, char *path, TBOOLEAN *subtopics); diff --git a/src/set.c b/src/set.c index 84d7d8303..cf73752e7 100644 --- a/src/set.c +++ b/src/set.c @@ -48,6 +48,7 @@ #include "gp_hist.h" #include "gp_time.h" #include "gplocale.h" +#include "help.h" #include "hidden3d.h" #include "jitter.h" #include "loadpath.h" @@ -90,6 +91,7 @@ static void set_dummy(void); static void set_encoding(void); static void set_fit(void); static void set_grid(void); +static void set_help(void); static void set_hidden3d(void); static void set_history(void); static void set_pixmap(void); @@ -299,6 +301,9 @@ set_command() case S_GRID: set_grid(); break; + case S_HELP: + set_help(); + break; case S_HIDDEN3D: set_hidden3d(); break; @@ -2047,6 +2052,22 @@ set_grid() } +/* process 'set help {rows|columns}' */ +static void +set_help() +{ +#ifndef NO_GIH + c_token++; + if (almost_equals(c_token,"col$umns")) + help_sort_by_rows = FALSE; + else if (almost_equals(c_token,"row$s")) + help_sort_by_rows = TRUE; + else + int_error(c_token, "unrecognized option"); + c_token++; +#endif +} + /* process 'set hidden3d' command */ static void set_hidden3d() diff --git a/src/show.c b/src/show.c index 11563d4b2..0726a40a4 100644 --- a/src/show.c +++ b/src/show.c @@ -47,6 +47,7 @@ #include "fit.h" #include "gp_time.h" #include "graphics.h" +#include "help.h" #include "hidden3d.h" #include "jitter.h" #include "misc.h" @@ -101,6 +102,7 @@ static void show_style_rectangle(void); static void show_style_circle(void); static void show_style_ellipse(void); static void show_grid(void); +static void show_help(void); static void show_raxis(void); static void show_paxis(void); static void show_zeroaxis(AXIS_INDEX); @@ -262,6 +264,9 @@ show_command() case S_GRID: show_grid(); break; + case S_HELP: + show_help(); + break; case S_RAXIS: show_raxis(); break; @@ -1751,6 +1756,16 @@ show_grid() fprintf(stderr, "\tGrid drawn at %s\n", (grid_layer==-1) ? "default layer" : ((grid_layer==0) ? "back" : "front")); } +/* process 'show help' command */ +static void +show_help() +{ +#ifndef NO_GIH + fprintf(stderr,"\thelp subtopics are sorted by %s\n", + help_sort_by_rows ? "row" : "column"); +#endif +} + static void show_raxis() { diff --git a/src/tables.c b/src/tables.c index 03c4d2ac5..c60de6a0a 100644 --- a/src/tables.c +++ b/src/tables.c @@ -205,6 +205,7 @@ const struct gen_table set_tbl[] = { "fu$nction", S_FUNCTIONS }, { "fu$nctions", S_FUNCTIONS }, { "g$rid", S_GRID }, + { "help", S_HELP }, { "hid$den3d", S_HIDDEN3D }, { "historysize", S_HISTORYSIZE }, /* Deprecated */ { "his$tory", S_HISTORY }, diff --git a/src/tables.h b/src/tables.h index 49e14adef..e8aa5f754 100644 --- a/src/tables.h +++ b/src/tables.h @@ -75,7 +75,7 @@ enum set_id { S_BOXDEPTH, S_BOXWIDTH, S_CLABEL, S_CLIP, S_CNTRPARAM, S_CNTRLABEL, S_CONTOUR, S_COLOR, S_COLORMAP, S_COLORSEQUENCE, S_CORNERPOLES, S_DASHTYPE, S_DATA, S_DATAFILE, S_DECIMALSIGN, S_DGRID3D, S_DUMMY, S_ENCODING, - S_FIT, S_FONTPATH, S_FORMAT, S_FUNCTIONS, S_GRID, + S_FIT, S_FONTPATH, S_FORMAT, S_FUNCTIONS, S_GRID, S_HELP, S_HIDDEN3D, S_HISTORY, S_HISTORYSIZE, S_ISOSAMPLES, S_ISOTROPIC, S_PIXMAP, S_JITTER, S_KEY, S_LABEL, S_LINK, S_NONLINEAR, S_LINESTYLE, S_LINETYPE, S_LOADPATH, S_LOCALE, S_LOGSCALE, S_MACROS, From db10c38ee1df1fd7e59133bb5be34700abdad9f9 Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Thu, 2 Feb 2023 22:53:03 -0800 Subject: [PATCH 028/192] Treat set_color(NaN) as LT_NODRAW rather than LT_BACKGROUND That is, NaN now triggers term->linetype(LT_NODRAW) rather than term->set_color(BACKGROUND_COLOR). I think this is clearly better if you are actually drawing lines. If you are using it for solid fill I think the result is terminal-dependent. Some will not draw anything (good) and others might use the "color" of LT_NODRAW which is background color (not as good but the same as it was doing before). --- src/color.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/color.c b/src/color.c index b0e9fa09b..3902c7837 100644 --- a/src/color.c +++ b/src/color.c @@ -213,16 +213,19 @@ invalidate_palette() Set the colour on the terminal Each terminal takes care of remembering the current colour, so there is not much to do here. - FIXME: NaN could alternatively map to LT_NODRAW or TC_RGB full transparency */ void set_color(double gray) { t_colorspec color; - color.value = gray; - color.lt = LT_BACKGROUND; - color.type = (isnan(gray)) ? TC_LT : TC_FRAC; - term->set_color(&color); + + if (isnan(gray)) { + term->linetype(LT_NODRAW); + } else { + color.type = TC_FRAC; + color.value = gray; + term->set_color(&color); + } } void From 30569abf80dd15ef995bdc212c5af806765532dd Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Fri, 3 Feb 2023 09:53:04 -0800 Subject: [PATCH 029/192] postscript terminal: do a better job of not drawing LT_NODRAW It was treating this as a dash pattern with dots separated by a lot of distance. But it did draw the line, so those widely space dots could appear in the rendered graph. Now we convert all the component vector draws to moves, so nothing is actually drawn. --- term/post.trm | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/term/post.trm b/term/post.trm index 6c0ab6c9c..dd0f33c81 100644 --- a/term/post.trm +++ b/term/post.trm @@ -547,6 +547,7 @@ PS_escape_string(char *origstr, char *escapelist) static int PS_pen_x, PS_pen_y; static int PS_taken; static int PS_linetype_last; +static int PS_dashtype_current; static double PS_linewidth_last; static double PS_linewidth_current; static TBOOLEAN PS_relative_ok; @@ -2064,6 +2065,7 @@ PS_dashtype(int type, t_dashtype *custom_dash_type) PS_linetype(type); break; } + PS_dashtype_current = type; } TERM_PUBLIC void @@ -2183,7 +2185,10 @@ PS_vector(unsigned int x, unsigned int y) if (!PS_relative_ok) PS_move(PS_pen_x, PS_pen_y); - if (strlen(rel) < strlen(abso)) { + if (PS_dashtype_current == DASHTYPE_NODRAW) { + PS_move(x,y); + ps_path_count = 1; + } else if (strlen(rel) < strlen(abso)) { fputs(rel, gppsfile); PS_taken++; /* only used for debug info */ ps_path_count += 1; From 6107dfdd9f253ea9d6edff0f410213b4fb23977d Mon Sep 17 00:00:00 2001 From: Ethan A Merritt Date: Fri, 3 Feb 2023 15:16:11 -0800 Subject: [PATCH 030/192] docs: Update Japanese doc files by copying from 6.1 branch --- docs/allterm-ja.h | 44 +- docs/gnuplot-ja.doc | 1302 ++++++++++++++++--------------------------- docs/term-ja.diff | 328 ++++++----- docs/title-ja.tex | 4 +- 4 files changed, 655 insertions(+), 1023 deletions(-) diff --git a/docs/allterm-ja.h b/docs/allterm-ja.h index 0ddb7d37b..ee8bc0b2b 100644 --- a/docs/allterm-ja.h +++ b/docs/allterm-ja.h @@ -3931,7 +3931,6 @@ START_HELP(gif) " `butt` ã¯ç·šåˆ†ã®æç”»ã§ã€ãã®ç«¯ã®ç‚¹ã§ã®ã¯ã¿ã ã—ã‚’èµ·ã“ã•ãªã„æç”»ãƒ¡ã‚½ãƒƒãƒ‰", " を使ã†ã‚ˆã†ãƒ‰ãƒ©ã‚¤ãƒã«æŒ‡ç¤ºã—ã¾ã™ã€‚ã“ã®è¨­å®šã¯ã€ç·šå¹…㌠1 より大ãã„å ´åˆã«", " ã®ã¿æœ‰åйã§ã™ã€‚ã“ã®è¨­å®šã¯ã€æ°´å¹³ç·šã€åž‚ç›´ç·šã®æç”»ã®å ´åˆã«æœ‰ç”¨ã§ã—ょã†ã€‚", -" デフォルト㯠`rounded` (丸ã‚) ã§ã™ã€‚", "", " 出力æç”»ã‚µã‚¤ã‚º ã¯ãƒ”クセルå˜ä½ã§ä¸Žãˆã¾ã™ã€‚デフォルト㯠640x480 ã§", " ã™ã€‚以下もå‚ç…§: `canvas`, `set size`。", @@ -4379,8 +4378,7 @@ START_HELP(jpeg) "", " `butt` ã¯ç·šåˆ†ã®æç”»ã§ã€ãã®ç«¯ã®ç‚¹ã§ã®ã¯ã¿ã ã—ã‚’èµ·ã“ã•ãªã„æç”»ãƒ¡ã‚½ãƒƒãƒ‰", " を使ã†ã‚ˆã†ãƒ‰ãƒ©ã‚¤ãƒã«æŒ‡ç¤ºã—ã¾ã™ã€‚ã“ã®è¨­å®šã¯ã€ç·šå¹…㌠1 より大ãã„å ´åˆã«", -" ã®ã¿æœ‰åйã§ã™ã€‚ã“ã®è¨­å®šã¯ã€æ°´å¹³ç·šã€åž‚ç›´ç·šã®æç”»ã®å ´åˆã«æœ‰ç”¨ã§ã—ょã†ã€‚", -" デフォルト㯠`rounded` (丸ã‚) ã§ã™ã€‚", +" ã®ã¿æ„味ãŒã‚りã¾ã™ã€‚ã“ã®é€†ã¯ `rounded` ã§ã™ã€‚", "", " フォントã®é¸æŠžã®è©³ç´°ã¯ã€ã‚„や複雑ã§ã™ã€‚", " 以下ã«åŒã˜æ„味をæŒã¤ç°¡å˜ãªä¾‹ã‚’示ã—ã¾ã™:", @@ -4590,6 +4588,8 @@ START_HELP(lua) #ifdef HAVE_LUA #ifndef JAPANESE_DOC #include "gnuplot-tikz.help" + + #endif #endif "" @@ -4796,7 +4796,7 @@ START_HELP(pcl5) " `pcl5` 出力形å¼ã¯ã€`encoding` ã®è¨­å®šã«åˆã†ãƒ•ã‚©ãƒ³ãƒˆã‚’è¦æ±‚ã—よã†ã¨ã—ã¾ã™ã€‚", " ã“ã‚Œã¯æœ€é«˜ã®å„ªå…ˆåº¦ã‚’æŒã¤ã®ã§ã€çµæžœçš„ã«é•ã†ãƒ•ォントã®è¦‹ãŸç›®ã«ãªã£ã¦ã—ã¾", " ã‹ã‚‚ã—れãªã„ã“ã¨ã«æ³¨æ„ã—ã¦ãã ã•ã„。ã“ã®å‡ºåŠ›ãƒ‰ãƒ©ã‚¤ãƒã®ãƒ‡ãƒ•ォルトã®", -" `encoding` ã¯ã€`HP Roman-8` ã§ã™ã€‚", +" `encoding` ã¯ã€`HP Roman-8` ã§ã™ã€‚", "", " 制é™:", "", @@ -5344,17 +5344,18 @@ START_HELP(png) " ç·šã«å½±éŸ¿ã‚’与ãˆã¾ã™ã€‚ã™ãªã‚ã¡ã€ã“ã‚Œã‚‰ã¯æ§˜ã€…ãªæç”»ã‚³ãƒžãƒ³ãƒ‰ã§è¦æ±‚ã•れる値", " ã«ã‹ã‘ç®—ã•れã¾ã™ã€‚", "", -" デフォルトã§ã¯ã€å‡ºåŠ›ã•れる PNG ç”»åƒã¯ 256 個ã«ç•ªå·ä»˜ã‘られãŸè‰²ã‚’使用ã—", -" ã¾ã™ã€‚代ã‚りã«ã‚ªãƒ—ション `truecolor` を使ãˆã°ã€24 ビット/ピクセルã®è‰²", -" 情報をæŒã¤ TrueColor ç”»åƒãŒç”Ÿæˆã•れã¾ã™ã€‚逿˜ŽåŒ–塗りã¤ã¶ã— (transparent", -" fill) を使用ã™ã‚‹ã¨ãã¯ã€ã“ã®ã‚ªãƒ—ション `truecolor` ãŒå¿…è¦ã«ãªã‚Šã¾ã™ã€‚", -" 以下å‚ç…§: `fillstyle`。背景ã®é€æ˜ŽåŒ–ã¯ã€ç•ªå·ä»˜ã‘ç”»åƒã‹ TrueColor ç”»åƒã§", -" å¯èƒ½ã§ã™ã€‚", +" デフォルトã§ã¯ã€png 出力形å¼ã¯ã€1 ピクセル毎㫠24bit ã®è‰²æƒ…報をæŒã¤", +" TrueColor ç”»åƒç”Ÿæˆã—ã¾ã™ã€‚オプション `notruecolor` ã¯ã€ä»£ã‚り㫠8bit", +" 色ã®ã¿ã®ç”»åƒ (256 個ã«ç•ªå·ä»˜ã‘られãŸè‰²) を使用ã—ã¾ã™ã€‚逿˜ŽåŒ–塗りã¤ã¶ã—", +" スタイル (transparent fill style) ã«ã¯ã€ã‚ªãƒ—ション `truecolor` ãŒå¿…è¦", +" ã§ã™ã€‚以下å‚ç…§: `fillstyle`。背景ã®é€æ˜ŽåŒ–ã¯ã€ç•ªå·ä»˜ã‘ç”»åƒã‹ TrueColor", +" ç”»åƒã§å¯èƒ½ã§ã™ã€‚アンãƒã‚¨ã‚¤ãƒªã‚¢ã‚¹ã«ã‚‚ TrueColor ãŒå¿…è¦ã§ã™ã€‚", "", " `butt` ã¯ç·šåˆ†ã®æç”»ã§ã€ãã®ç«¯ã®ç‚¹ã§ã®ã¯ã¿ã ã—ã‚’èµ·ã“ã•ãªã„æç”»ãƒ¡ã‚½ãƒƒãƒ‰", " を使ã†ã‚ˆã†ãƒ‰ãƒ©ã‚¤ãƒã«æŒ‡ç¤ºã—ã¾ã™ã€‚ã“ã®è¨­å®šã¯ã€ç·šå¹…㌠1 より大ãã„å ´åˆã«", -" ã®ã¿æœ‰åйã§ã™ã€‚ã“ã®è¨­å®šã¯ã€æ°´å¹³ç·šã€åž‚ç›´ç·šã®æç”»ã®å ´åˆã«æœ‰ç”¨ã§ã—ょã†ã€‚", -" デフォルト㯠`rounded` (丸ã‚) ã§ã™ã€‚", +" ã®ã¿æ„味ãŒã‚りã¾ã™ã€‚ã“れã®é€†ãŒ `rounded` ã§ã€ã‚¢ãƒ³ãƒã‚¨ã‚¤ãƒªã‚¢ã‚¹ãŒæœ‰åйã§", +" ãªã„å ´åˆ (`notruecolor`) 多少よりå‡ä¸€ãªæ›²ç·šã‚’生æˆã—ã¾ã™ãŒã€ã‚ˆã‚Šé…ããª", +" りã¾ã™ã€‚", "", " フォントã®é¸æŠžã®è©³ç´°ã¯ã€ã‚„や複雑ã§ã™ã€‚", " 以下ã«åŒã˜æ„味をæŒã¤ç°¡å˜ãªä¾‹ã‚’示ã—ã¾ã™:", @@ -5370,19 +5371,14 @@ START_HELP(png) "", "2 例", "?set term png examples", -" set terminal png medium size 640,480 background '#ffffff'", -"", -" ã“ã®ä¾‹ã¯ medium サイズã®ã€å¤§ãã•変更ä¸èƒ½ã§å›žè»¢ã§ããªã„組ã¿è¾¼ã¿ãƒ•ォント", -" を使用ã—ã€é€æ˜ŽåŒ–ã•れãªã„背景色ã¨ã—ã¦ç™½ (16 進数㮠24bit RGB) を使用ã—ã¾", -" ã™ã€‚", "", -" set terminal png font arial 14 size 800,600", +" set terminal png font \"arial,14\" size 800,600 background \"white\"", "", " ã“れã¯ã€'arial' ã¨ã„ã†ãƒ•ェースåã®ã‚¹ã‚±ãƒ¼ãƒ©ãƒ–ルフォントを検索ã—ã€ãƒ•ォン", " トサイズを 14pt ã«è¨­å®šã—ã¾ã™ã€‚ãƒ•ã‚©ãƒ³ãƒˆã®æ¤œç´¢ãŒã©ã®ã‚ˆã†ã«è¡Œã‚れるã‹ã«ã¤", " ã„ã¦ã¯ä»¥ä¸‹å‚ç…§: `fonts`。", "", -" set terminal png transparent truecolor enhanced", +" set terminal png transparent enhanced", "", " ã“れã¯ã€24 ビット/ピクセルã®è‰²æƒ…報を使用ã—ã€èƒŒæ™¯ã‚’逿˜ŽåŒ–ã—ã¾ã™ã€‚ãã—ã¦", " 表示ã•れる文字列ã®é…置制御ã¨ã—㦠`enhanced text` モードを使用ã—ã¾ã™ã€‚", @@ -6745,8 +6741,8 @@ START_HELP(sixelgd) "", " `butt` ã¯ç·šåˆ†ã®æç”»ã§ã€ãã®ç«¯ã®ç‚¹ã§ã®ã¯ã¿ã ã—ã‚’èµ·ã“ã•ãªã„æç”»ãƒ¡ã‚½ãƒƒãƒ‰", " を使ã†ã‚ˆã†ãƒ‰ãƒ©ã‚¤ãƒã«æŒ‡ç¤ºã—ã¾ã™ã€‚ã“ã®è¨­å®šã¯ã€ç·šå¹…㌠1 より大ãã„å ´åˆã«", -" ã®ã¿æœ‰åйã§ã™ã€‚ã“ã®è¨­å®šã¯ã€æ°´å¹³ç·šã€åž‚ç›´ç·šã®æç”»ã®å ´åˆã«æœ‰ç”¨ã§ã—ょã†ã€‚", -" デフォルト㯠`rounded` (丸ã‚) ã§ã™ã€‚", +" ã®ã¿æ„味ãŒã‚りã¾ã™ã€‚ã“れã®é€†ãŒ `rounded` ã§ã€å¤šå°‘よりå‡ä¸€ãªæ›²ç·šã‚’生æˆ", +" ã—ã¾ã™ãŒã€ã‚ˆã‚Šé…ããªã‚Šã¾ã™ã€‚", "", " フォントã®é¸æŠžã®è©³ç´°ã¯ã€ã‚„や複雑ã§ã™ã€‚", " 詳細ã¯ã€ä»¥ä¸‹å‚ç…§: `fonts`。", @@ -9334,9 +9330,9 @@ START_HELP(x11) "", " ã¯ãƒ•ォントã®åŸºæœ¬å (base name) (例: Times, Symbol)", " ã¯ãƒã‚¤ãƒ³ãƒˆã‚µã‚¤ã‚º (指定ãŒãªã‘れã°ãƒ‡ãƒ•ォルト㯠12)", -" 㯠==\"italic\" ãªã‚‰ `i`, ==\"oblique\" ãªã‚‰ `o`, ãã®ä»–㯠`r`", -" ã¯æ˜Žç¤ºçš„ã«æŒ‡å®šã•れれ㰠`medium` ã‹ `bold`ã€ãã®ä»–㯠`*`", -" ã¯ç¾åœ¨ã®æ–‡å­—集åˆã«åŸºã¥ã„ã¦è¨­å®š (以下å‚ç…§: `set encoding`)", +" 㯠==\"italic\" ãªã‚‰ 'i', ==\"oblique\" ãªã‚‰ 'o', ãã®ä»–㯠'r'", +" ã¯æ˜Žç¤ºçš„ã«æŒ‡å®šã•れれ㰠'medium' ã‹ 'bold'ã€ãã®ä»–㯠'*'", +" ã¯ç¾åœ¨ã®æ–‡å­—集åˆã«åŸºã¥ã„ã¦è¨­å®šã€‚", " よã£ã¦ `set term x11 font \"arial,15,italic\"` 㯠(デフォルト㮠encoding", " ã ã¨ã™ã‚Œã°) -*-arial-*-i-*-*-15-*-*-*-*-*-iso8859-1 ã«å¤‰æ›ã•れã¾ã™ã€‚", " , , 指定ã¯ã„ãšã‚Œã‚‚å¿…é ˆã§ã¯ã‚りã¾ã›ã‚“。 ã‚„", diff --git a/docs/gnuplot-ja.doc b/docs/gnuplot-ja.doc index 0865c4d05..8e645a18a 100644 --- a/docs/gnuplot-ja.doc +++ b/docs/gnuplot-ja.doc @@ -1,5 +1,5 @@ -C RCS $Id: gnuplot-ja.doc,v 1.768 2022-12-12 18:12:59+09 shige Exp $ -C corresponding original gnuplot.doc at 2022-12-12 +C RCS $Id: gnuplot-ja.doc,v 1.778 2023-01-23 13:36:27+09 shige Exp $ +C corresponding original gnuplot.doc at 2023-01-23 C C Copyright (C) 1986 - 1993, 1998, 1999, 2000, 2001, 2004 Thomas Williams, Colin Kelley et al. C @@ -40,6 +40,7 @@ C ?copyright ?license Copyright (C) 1986 - 1993, 1998, 2004, 2007 Thomas Williams, Colin Kelley + Copyright (C) 2004-2023 various authors Permission to use, copy, and distribute this software and its documentation for any purpose with or without fee is hereby granted, @@ -73,13 +74,14 @@ C Russell Lang, Dave Kotz, John Campbell. Gnuplot 3.0 additions: Gershon Elber and many others. - Gnuplot 4.0 and 5.0 additions: + Gnuplot 4.0 and subsequent releases: See list of contributors at head of this document. (°Ê²¼¤ª¤ª¤Þ¤«¤ÊÌõ; Ìõ¤ÏÀµ¤·¤¯¤Ê¤¤¤«¤âÃΤì¤Þ¤»¤ó¤Î¤Ç¾Ü¤·¤¯¤Ï¾åµ­¤Î¸¶Ê¸ ¤òÅö¤¿¤Ã¤Æ¤¯¤À¤µ¤¤¡£Ìõ¼Ô¤ÏÀÕǤ¤ò»ý¤Á¤Þ¤»¤ó¡£) Copyright (C) 1986 - 1993, 1998, 2004, 2007 Thomas Williams, Colin Kelley + Copyright (C) 2004-2023 ¿¤¯¤ÎÃø¼Ô ¤³¤Î¥½¥Õ¥È¥¦¥§¥¢¤È¤½¤ÎÉÕ°ʸ½ñ¤Î»ÈÍÑ¡¢Ê£À½¡¢ÇÛÉۤεö²Ä¤Ï¡¢¾åµ­¤ÎÃøºî¸¢ (copyright) ɽ¼¨¤¬¡¢Á´¤Æ¤ÎÊ£À½Êª¤Ë½ñ¤«¤ì¤Æ¤¤¤ë¤³¤È¡¢¤ª¤è¤ÓÃøºî¸¢É½¼¨¤È @@ -111,7 +113,7 @@ C Russell Lang, Dave Kotz, John Campbell. Gnuplot 3.0 ÄɲÃ: Gershon Elber ¤È¤½¤Î¾¤Î¿Í¡¹¡£ - Gnuplot 4.0, 5.0 ÄɲÃ: + Gnuplot 4.0 ¤ª¤è¤Ó¤½¤ì°Ê¹ß¤Î¥ê¥ê¡¼¥¹: ¤³¤Îʸ½ñ¤ÎÀèÆ¬¤Î´óÍ¿¼Ô (contributors) ¤Î°ìÍ÷»²¾È¡£ 2 ¤Ï¤¸¤á¤Ë (Introduction) ?introduction @@ -126,19 +128,21 @@ C ¥·¥ç¥ó¤ÎÉÁ²è¥¨¥ó¥¸¥ó¤È¤·¤Æ¤â»È¤ï¤ì¤Æ¤¤¤Þ¤¹¡£gnuplot ¤Ï¡¢1986 ¤è¤ê¥µ¥Ý ¡¼¥È¤È³èȯ¤Ê³«È¯¤¬¹Ô¤ï¤ì¤Æ¤¤¤Þ¤¹¡£ - gnuplot ¤Ï¡¢2 ¼¡¸µ¡¢¤Þ¤¿¤Ï 3 ¼¡¸µ¤Î¡¢Â¿¤¯¤Î¼ïÎà¤Î¥°¥é¥Õ¤ò¥µ¥Ý¡¼¥È¤·¤Æ - ¤¤¤Þ¤¹: ÀÞÀþ¥°¥é¥Õ¡¢ÅÀ¥°¥é¥Õ¡¢ËÀ¥°¥é¥Õ¡¢Åù¹âÀþ¡¢¥Ù¥¯¥È¥ë¾ìÉÁ²è¡¢¶ÊÌÌ¡¢ - ¤½¤·¤Æ¤½¤ì¤é¤Ë´ØÏ¢¤¹¤ë¤µ¤Þ¤¶¤Þ¤Êʸ»úÎóÅù¡£¤½¤·¤Æ¤µ¤é¤Ë¤¤¤¯¤Ä¤«¤ÎÆÃÊÌ¤Ê - ÉÁ²è·¿¤â¥µ¥Ý¡¼¥È¤·¤Æ¤¤¤Þ¤¹¡£ + gnuplot ¤Ï¡¢2 ¼¡¸µ¡¢¤Þ¤¿¤Ï 3 ¼¡¸µ¤Î¿¤¯¤Î¼ïÎà¤Î¥°¥é¥Õ¤òÀ¸À®¤Ç¤­¤Þ¤¹¡£ + ¤¤¤Þ¤¹: ÀÞÀþ¥°¥é¥Õ¡¢ÅÀ¥°¥é¥Õ¡¢ËÀ¥°¥é¥Õ¡¢Åù¹âÀþ¡¢¥Ù¥¯¥È¥ë¾ìÉÁ²è¡¢²èÁü¤Î + ¼è¤ê¹þ¤ß¡¢¶ÊÌÌ¡¢¤½¤·¤Æ¤½¤ì¤é¤Ë´ØÏ¢¤¹¤ë¤µ¤Þ¤¶¤Þ¤Êʸ»úÎóÅù¡£¤½¤·¤Æ¤µ¤é¤Ë + ¤¤¤¯¤Ä¤«¤ÎÆÃÊ̤ʥ°¥é¥Õ¡¢Î㤨¤Ð²¹ÅÙʬÉÛ¿Þ (heatmap)¡¢ÃØéá¤ÎÁ㥰¥é¥Õ (¥ì + ¡¼¥À¡¼¥Á¥ã¡¼¥È, spiderplot)¡¢¶Ë¼Í±Æ (polar projection)¡¢¥Ò¥¹¥È¥°¥é¥à + (histograms)¡¢È¢¤Ò¤²¿Þ (boxplot)¡¢¥Ó¡¼¥¹¥¦¥©¡¼¥à¥°¥é¥Õ (bee swarm)¡¢ + ÈóÀþ·Á¼´¤Ê¤É¤â¥µ¥Ý¡¼¥È¤·¤Æ¤¤¤Þ¤¹¡£ gnuplot ¤Ï¿¤¯¤Î°Û¤Ê¤ë½ÐÎϤò¥µ¥Ý¡¼¥È¤·¤Æ¤¤¤Þ¤¹: ÂÐÏ÷¿¥¹¥¯¥ê¡¼¥ó½ÐÎÏ·Á ¼° (¥Þ¥¦¥¹¤ä¥Û¥Ã¥È¥­¡¼ÆþÎϤâ²Äǽ)¡¢¥Ú¥ó¥×¥í¥Ã¥¿¤ä¸½ºß¤Î¥×¥ê¥ó¥¿¤Ø¤Îľ ÀܽÐÎÏ¡¢¤Þ¤¿¤Ï¿¤¯¤Î¥Õ¥¡¥¤¥ë·Á¼°¤Ø¤Î½ÐÎÏ (eps, emf, fig, jpeg, LaTeX, pdf, png, postscript, ...)¡£gnuplot ¤Ï¡¢Íưפ˿·¤·¤¤½ÐÎÏ·Á¼°¤òÄɲ乤ë - ¤è¤¦³ÈÄ¥¤¹¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ºÇ¶áÄɲ䵤줿ÂÐÏ÷¿½ÐÎÏ·Á¼°¤Ë¤Ï¡¢ - wxWidgets (Ê£¿ô¤Î¥×¥é¥Ã¥È¥Û¡¼¥à¤ÇÍøÍѲÄǽ), Qt ¤ò¸µ¤Ë¤·¤¿¤â¤Î¤¬¤¢¤ê¤Þ - ¤¹¡£svg ¤ä HTML5 canvas ½ÐÎÏ·Á¼°¤òÍøÍѤ¹¤ì¤Ð¡¢¥°¥é¥Õ¤ò Web ¥Ú¡¼¥¸Æâ¤Ë - ¥Þ¥¦¥¹ÍøÍѲÄǽ¤Ê·Á¤ÇËä¤á¹þ¤ó¤À½ÐÎϤòÀ¸À®¤¹¤ë¤³¤È¤â¤Ç¤­¤Þ¤¹¡£ + ¤è¤¦³ÈÄ¥¤¹¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ºÇ¶á¤Ç¤ÏÎ㤨¤Ð webp ¥¢¥Ë¥á¡¼¥·¥ç¥ó¤¬¥µ¥Ý¡¼ + ¥È¤µ¤ì¤Þ¤·¤¿¡£svg ¤ä HTML5 canvas ½ÐÎÏ·Á¼°¤òÍøÍѤ¹¤ì¤Ð¡¢¥°¥é¥Õ¤ò Web + ¥Ú¡¼¥¸Æâ¤Ë¥Þ¥¦¥¹ÍøÍѲÄǽ¤Ê·Á¤ÇËä¤á¹þ¤ó¤À½ÐÎϤòÀ¸À®¤¹¤ë¤³¤È¤â¤Ç¤­¤Þ¤¹¡£ `gnuplot` ¤Î¥³¥Þ¥ó¥É¸À¸ì¤ÏÂçʸ»ú¾®Ê¸»ú¤ò¶èÊ̤·¤Þ¤¹¡£¤¹¤Ê¤ï¤Á¡¢¾®Ê¸»ú¤Ç ½ñ¤«¤ì¤¿¥³¥Þ¥ó¥É¤ä´Ø¿ô̾¤Ï¡¢¤½¤ì¤é¤òÂçʸ»ú¤Ç½ñ¤¤¤¿¤â¤Î¤È¤ÏƱ¤¸¤Ç¤Ï¤¢¤ê @@ -180,10 +184,6 @@ C gnuplot {OPTIONS} file1 file2 ... ¤³¤³¤Ç file1, file2 Åù¤Ï¡¢`local` ¥³¥Þ¥ó¥É¤Ç¼è¤ê¹þ¤à¤Î¤ÈƱÅù¤ÎÆþÎÏ¥Õ¥¡ ¥¤¥ë (¥¹¥¯¥ê¥×¥È¥Õ¥¡¥¤¥ë) ¤Ç¤¹¡£ - X11 ¥Ù¡¼¥¹¤Î¥·¥¹¥Æ¥à¤Ç¤Ï¡¢°Ê²¼¤Î½ñ¼°¤¬»È¤¨¤Þ¤¹¡£ - gnuplot {X11OPTIONS} {OPTIONS} file1 file2 ... - ¾ÜºÙ¤Ï¡¢X11 ¤Î¥É¥­¥å¥á¥ó¥È¡¢¤ª¤è¤Ó°Ê²¼»²¾È: `x11`¡£ - gnuplot ¤ËÍ¿¤¨¤ë¥ª¥×¥·¥ç¥ó¤Ï¡¢¥³¥Þ¥ó¥É¹Ô¤Î¤É¤³¤ËÃÖ¤¤¤Æ¤â¹½¤¤¤Þ¤»¤ó¡£¥Õ ¥¡¥¤¥ë¤Ï»ØÄꤷ¤¿½ç¤Ë¼Â¹Ô¤µ¤ì¡¢Æ±ÍÍ¤Ë -e ¥ª¥×¥·¥ç¥ó¤ÇǤ°Õ¤Î¥³¥Þ¥ó¥É¤òÍ¿ ¤¨¤ë¤³¤È¤â¤Ç¤­¤Þ¤¹¡£Îã: @@ -192,19 +192,18 @@ C ÆÃÊ̤ʥե¡¥¤¥ë̾ "-" ¤Ï¡¢É¸½àÆþÎϤ«¤éÆÉ¤Þ¤»¤ë¤Î¤Ë»È¤¤¤Þ¤¹¡£`gnuplot` ¤ÏºÇ¸å¤Î¥Õ¥¡¥¤¥ë¤ò½èÍý¤·½ª¤ï¤ë¤È½ªÎ»¤·¤Þ¤¹¡£ÆÉ¤ß¹þ¤Þ¤»¤ë¥Õ¥¡¥¤¥ë¤ò°ì¤Ä ¤â»ØÄꤷ¤Ê¤¤¾ì¹ç¤Ï¡¢`gnuplot` ¤Ïɸ½àÆþÎϤ«¤é¤ÎÂÐÏÃÆþÎϤò¼è¤ê¤Þ¤¹¡£¾ÜºÙ - ¤Ï¡¢°Ê²¼»²¾È: `batch/interactive`¡£gnuplot ÍѤΥª¥×¥·¥ç¥ó¤Ë¤Ä¤¤¤Æ¤Ï¡¢ - °Ê²¼¤Î¤è¤¦¤Ë¤·¤Æ°ìÍ÷¤ò¸«¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹: + ¤Ï¡¢°Ê²¼»²¾È: `batch/interactive`¡£ + ¥³¥Þ¥ó¥É¥é¥¤¥ó¥ª¥×¥·¥ç¥ó¤Î¾ÜºÙ¤Ï°Ê²¼»²¾È: `command-line-options`¡£¤Þ¤¿ + ¤Ï°Ê²¼¤ò¼Â¹Ô¤·¤Æ¤¯¤À¤µ¤¤¡£ gnuplot --help - ¾ÜºÙ¤Ï°Ê²¼»²¾È: `command-line-options`¡£ ÂÐÏ÷¿ÉÁ²è¥¦¥£¥ó¥É¥¦¤Ç¤Îºî¶ÈÃæ¤Ï¡¢'h' ¤òÂǤĤȥۥåȥ­¡¼ (`hotkeys`) ¤È¥Þ¥¦¥¹µ¡Ç½ (`mousing`) ¤Ë´Ø¤¹¤ë¥Ø¥ë¥×¤ò¸«¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ - `seeking-assistance` ¤Î¥»¥¯¥·¥ç¥ó¤Ï¡¢¤µ¤é¤Ê¤ë¾ðÊó¤ä¥Ø¥ë¥×¡¢FAQ ¤òõ¤¹ - ¼ê³Ý¤ê¤òÍ¿¤¨¤Æ¤¯¤ì¤ë¤Ç¤·¤ç¤¦¡£ -2 õ¤·½Ð¤¹¼ê½õ¤± (Seeking-assistance) +2 õ¤·½Ð¤¹¼ê½õ¤±/¥Ð¥° (Seeking-assistance / Bugs) ?help-desk ?faq ?FAQ +?bugs ?seeking-assistance ¸ø¼°¤Î gnuplot ¥Û¡¼¥à¥Ú¡¼¥¸¤Ï°Ê²¼¤Ë¤¢¤ê¤Þ¤¹¡£ ^ @@ -249,23 +248,55 @@ C ³«È¯ÈǤ˴ؤ¹¤ë¥á¡¼¥ê¥ó¥°¥ê¥¹¥È: gnuplot-beta@lists.sourceforge.net -2 ¸½ºß¤Î¥Ð¡¼¥¸¥ç¥ó¤Î¿·¤·¤¤µ¡Ç½ (New features in this version) -?new version_5.5 +2 ¥Ð¡¼¥¸¥ç¥ó 6 ¤Ç¤Î¿·¤·¤¤µ¡Ç½ (New features in version 6) +?new version_6 ?new -?development version ?version - ¥Ð¡¼¥¸¥ç¥ó 5.5 ¤Ï¸½ºß¤Î³«È¯ÈǤǡ¢¤½¤ì¤Ï git ¥ê¥Ý¥¸¥È¥ê¤Ë¤¢¤ë¥Þ¥¹¥¿¡¼¥Ö - ¥é¥ó¥ÁÆâ¤Î¥½¡¼¥¹¥Õ¥¡¥¤¥ë¤Î¥¹¥Ê¥Ã¥×¥·¥ç¥Ã¥È¤ò»È¤Ã¤ÆºîÀ®¤Ç¤­¤Þ¤¹¡£¤½¤ì¤Ë - ƳÆþ¤µ¤ì¤¿¿·¤·¤¤µ¡Ç½¤Ï¡¢°ìÈ̤ˤϡ¢¥Ð¡¼¥¸¥ç¥ó 5.6 ¤Þ¤Ç¤ÎÀµ¼°ÈǤ˸½¤ì¤ë - ¤³¤È¤Ï¤¢¤ê¤Þ¤»¤ó¤·¡¢ºÙ¤«¤¤»ÅÍÍ¤ÏÆ³Æþ¤ÎÁ°¤ËÊѹ¹¤µ¤ì¤ë²ÄǽÀ­¤¬¤¢¤ê¤Þ¤¹¡£ + ¥Ð¡¼¥¸¥ç¥ó 6 ¤Ï¡¢Á̤뤳¤È 1986 ǯ¤«¤é¤Î gnuplot ³«È¯¤Ç¤ÎºÇ¿·¥á¥¸¥ã¡¼¥ê + ¥ê¡¼¥¹¤Ç¤¹¡£¤½¤ì¤Ï¡¢¥á¥¸¥ã¡¼¥Ð¡¼¥¸¥ç¥ó 5 (2015)¡¢¤½¤·¤Æ¤½¤Î¸å¤Î¥Þ¥¤¥Ê + ¡¼¥ê¥ê¡¼¥¹ 5.2 (2017), 5.4 (2020) ¤Ë³¤¯¤â¤Î¤Ç¤¹¡£³«È¯¤Ï¡¢SouceForge + ¾å¤Î git ¥ê¥Ý¥¸¥È¥ê¥×¥í¥¸¥§¥¯¥ÈÆâ¤Î¡¢Àµ¼°ÈǤȤÏÊ̤ʥ֥é¥ó¥Á¤Ç³¤±¤é¤ì + ¤Æ¤¤¤Þ¤¹¡£ - ¤¢¤Ê¤¿¤¬¼Â¹Ô¤·¤Æ¤¤¤ë gnuplot ¤ËÁȤ߹þ¤Þ¤ì¤¿¥ª¥×¥·¥ç¥óµ¡Ç½¤Ë´Ø¤¹¤ë¹¹¤Ê - ¤ë¾ðÊó¤Ë¤Ä¤¤¤Æ¤Ï¡¢°Ê²¼»²¾È: `show version long`¡£ + ¤³¤Î¥É¥­¥å¥á¥ó¥È¤Ëµ­½Ò¤µ¤ì¤Æ¤¤¤ëµ¡Ç½¤ÎÃæ¤Ë¤Ï¡¢gnuplot ¤ò¥½¡¼¥¹¤«¤é¥³¥ó + ¥Ñ¥¤¥ë¤¹¤ëºÝ¤Ë¤½¤ì¤òÁªÂò¤·¤ÆÀßÄꤷ¤Æ¤¤¤ë¾ì¹ç¤À¤±»È¤¨¤ë¤â¤Î¤¬¤¢¤ê¤Þ¤¹¡£ + ¤¢¤Ê¤¿¤¬¼Â¹Ô¤·¤Æ¤¤¤ëÆÃÄê¤Î gnuplot ¤¬¡¢¥³¥ó¥Ñ¥¤¥ë»þ¤Ë¤É¤Î¤è¤¦¤Ê¥ª¥×¥· + ¥ç¥ó¤òÀßÄꤷ¤Æºî¤é¤ì¤¿¤«¤òÃΤë¤Ë¤Ï¡¢`show version long` ¤È¥¿¥¤¥×¤·¤Æ¤¯ + ¤À¤µ¤¤¡£ + +3 ´Ø¿ô¥Ö¥í¥Ã¥¯¤È¶É½êÊÑ¿ô (Function blocks and scoped variables) +?new function blocks + ¤³¤ÎÈǤΠgnuplot ¤Ç¤Ï¡¢É¸½àŪ¤Ê gnuplot ¥³¥Þ¥ó¥É¤Î¥Ö¥í¥Ã¥¯¤ò¸Æ¤Ó½Ð¤·¤Æ + ´Ø¿ô¤È¤·¤Æ»È¤¨¤ëµ¡Ç½¤òƳÆþ¤·¤Æ¤¤¤Þ¤¹¡£´Ø¿ô¥Ö¥í¥Ã¥¯¤Ï¡¢0 ¤«¤é 9 ¸Ä¤Î°ú + ¿ô¤ò»È¤¨¤Æ¡¢°ì¤Ä¤ÎÃͤòÊÖ¤·¤Þ¤¹¡£´Ø¿ô¥Ö¥í¥Ã¥¯¤Ï¡¢·×»»¤·¤¿¿·¤·¤¤ÃͤòÊÑ¿ô + ¤Ë³ä¤êÅö¤Æ¤¿¤ê¡¢°Û¤Ê¤ë´Ø¿ô¤ä±é»»»Ò¤ò·ë¹ç¤·¤¿¤ê¡¢Í¿¤¨¤é¤ì¤¿¥Ç¡¼¥¿¤ËÂФ¹ + ¤ë·«¤êÊÖ¤·¤Îºî¶È¤ò¹Ô¤Ã¤¿¤ê¤¹¤ë¤Î¤Ë»È¤¦¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ + ¤³¤Î»ÅÁȤߤˤϡ¢3 ¤Ä¤ÎÍ×ÁǤ¬¤¢¤ê¤Þ¤¹¡£ + °Ê²¼»²¾È: `local`, `scope`, `function blocks`, `return`¡£ +#start +#b ½¤¾þ»Ò `local` ¤Ï¡¢ÊÑ¿ô¤äÇÛÎó¤Î¥ª¥×¥·¥ç¥óÀë¸À¤Ç¡¢¤½¤Î¥¹¥³¡¼¥×¤Ï¡¢¤½ +## ¤ì¤¬½ñ¤«¤ì¤Æ¤¤¤ë¥×¥í¥°¥é¥àñ°Ì¤Î¼Â¹ÔÃæ¤Î¤ß¤ËÀ©¸Â¤µ¤ì¤Þ¤¹¡£Ã±°Ì¤È¤Ï¡¢ +## ¸½ºß¤Ï¡¢`load` ¤ä `call` ʸ¤Î¼Â¹Ôñ°Ì¡¢´Ø¿ô¥Ö¥í¥Ã¥¯É¾²Á¡¢¤½¤·¤Æ `if`, +## `else`, `do for`, `while` ¤Ë³¤¯Ã椫¤Ã¤³¤Ç°Ï¤Þ¤ì¤¿¥³¡¼¥É¥Ö¥í¥Ã¥¯Ã±°Ì +## ¤Ç¤¹¡£¶É½ê (local) ÊÑ¿ô¤Î̾Á°¤¬Âç°è (global) ÊÑ¿ô¤Î̾Á°¤È¤Ö¤Ä¤«¤ë¾ì +## ¹ç¤Ï¡¢¤½¤Î¶É½ê¥¹¥³¡¼¥×¤«¤éÈ´¤±¤ë¤Þ¤Ç¤ÏÂç°èÊÑ¿ô¤Ï±£¤µ¤ì¤Þ¤¹¡£ +#b ¥³¥Þ¥ó¥É `function` ¤Ï¡¢gnuplot ¥³¥Þ¥ó¥É¤«¤é¤Ê¤ë̾Á°ÉÕ¤­´Ø¿ô¥Ö¥í¥Ã¥¯ +## (¼ÂºÝ¤Ï¤¢¤ëʸ»úÎó¤ÎÇÛÎó) ¤òÀë¸À¤·¤Þ¤¹¡£´Ø¿ô¥Ö¥í¥Ã¥¯¤ò¸Æ¤Ó½Ð¤¹¤È¡¢¤½ +## ¤Î¥³¥Þ¥ó¥É¤¬¡¢¥Ö¥í¥Ã¥¯¤ÎºÇ¸å¤Ë¤Ê¤ë¤«¡¢¤Þ¤¿¤Ï `return` ¥³¥Þ¥ó¥É¤ËÅö¤¿ +## ¤ë¤Þ¤Ç¡¢½ç¼¡¼Â¹Ô¤µ¤ì¤Þ¤¹¡£ +#b ¥³¥Þ¥ó¥É `return ` ¤Ï¡¢´Ø¿ô¥Ö¥í¥Ã¥¯¤Î¼Â¹Ô¤ò½ªÎ»¤·¤Þ¤¹¡£ +## ¼° ¤Îɾ²Á¤Î·ë²Ì¤¬¡¢¤½¤Î´Ø¿ô¤ÎÃͤȤ·¤ÆÊÖ¤µ¤ì¤Þ¤¹¡£´Ø¿ô¥Ö +## ¥í¥Ã¥¯¤Î³°¤Ç¤Ï¡¢¤É¤³¤Ç¤â `return` ¤Ï `exit` ¤ÈƱÍÍ¤ËÆ°ºî¤·¤Þ¤¹¡£ +#end + + ¤³¤Î»ÅÁȤߤò»È¤Ã¤Æ¡¢Ã±½ã¤Ê°ì¹Ô¤Î´Ø¿ôÄêµÁ `f(x) = ...` ¤è¤ê¤â¤Ã¤ÈÊ£»¨¤Ç + ¼«ÌÀ¤Ç¤Ï¤Ê¤¤´Ø¿ô¤òÄêµÁ¤·¡¢ÉÁ²è¤¹¤ëÎã¤È¤·¤Æ¡¢`function_block.dem` ¤ò»² + ¾È¤·¤Æ¤¯¤À¤µ¤¤¡£ 3 ÆÃ¼ì´Ø¿ô¤ÈÊ£ÁÇ¿ôÃÍ´Ø¿ô (Special and complex-valued functions) ?new math - gnuplot ¤Î¤³¤Î¥Ð¡¼¥¸¥ç¥ó¤Ç¤Ï¡¢Âô»³¤ÎÊ£ÁÇ¿ôÃÍ´Ø¿ô¤È¡¢°ÊÁ°¤Î¥Ð¡¼¥¸¥ç¥ó¤Ë - ¤¢¤Ã¤¿¤¤¤¯¤Ä¤«¤Î´Ø¿ô¤Î²þÎÉÈǤòÄ󶡤·¤Þ¤¹¡£ + gnuplot ¥Ð¡¼¥¸¥ç¥ó 6 ¤Ï¡¢ËÄÂç¤ÊÊ£ÁÇ¿ôÃÍ´Ø¿ô·²¤È¡¢°ÊÁ°¤Î¥Ð¡¼¥¸¥ç¥ó¤Ë¤¢ + ¤Ã¤¿´Ø¿ô¤Î²þÎÉÈǤò¤¤¤¯¤Ä¤«Ä󶡤·¤Þ¤¹¡£ #start #b ¿·µ¬: Ê£ÁÇÊÑ¿ô¡¢Ê£ÁÇ¿ôÃͤΥ꡼¥Þ¥ó¥¼¡¼¥¿ (¦Æ) ´Ø¿ô¡£°Ê²¼»²¾È: `zeta`¡£ #b (Àµµ¬²½) ²¼ÊýÉÔ´°Á´¥¬¥ó¥Þ´Ø¿ô¤ÎÄêµÁ°è¤ÈÀºÅ٤βþÎÉ¡£Ê£Áǰú¿ô¤¬²Äǽ¤Ë¡£ @@ -313,18 +344,19 @@ C ?new style #start #b ÉÁ²è¥¹¥¿¥¤¥ë `with surface` ¤Ï¡¢2 ¼¡¸µ¶ËºÂɸ¤Çưºî¤·¡¢Ê¿Ì̤ò¿§Åɤꤷ -## ¤¿³Ê»Òɽ¸½¤Î¥°¥é¥Õ¤òÀ¸À®¤·¤Þ¤¹ ¿§¤ÏÆþÎÏÅÀ¤ÎǤ°Õ¤Î½¸¹ç¤Î´óÍ¿¤Ë¤è¤ë½Å -## ¤ßÉÕ¤­¤è¤Ã¤Æ¿§ÉÕ¤±¤µ¤ì¤Þ¤¹¡£¤³¤ì¤Ï¡¢3 ¼¡¸µ³Ê»Ò¶ÊÌ̤òºî¤ë `dgrid3d`¤È -## ¥¹¥¿¥¤¥ë `with pm3d` ¤ÎÎà»÷ÉʤǤ¹¡£°Ê²¼»²¾È: `set polar grid`, -## `polar heatmap`¡£ +## ¤¿³Ê»Òɽ¸½¤Î¥°¥é¥Õ¤òÀ¸À®¤·¤Þ¤¹ ¿§¤ÏÆþÎÏÅÀ¤ÎǤ°Õ¤Î½¸¹ç¤Î¤«¤é¤Î´óÍ¿¤Ë +## ¤è¤ë½Å¤ßÉÕ¤­¤è¤Ã¤Æ¿§ÉÕ¤±¤µ¤ì¤Þ¤¹¡£¤³¤ì¤Ï¡¢3 ¼¡¸µ³Ê»Ò¶ÊÌ̤òºî¤ë +## `dgrid3d`¤È¥¹¥¿¥¤¥ë `with pm3d` ¤ÎÎà»÷ÉʤǤ¹¡£ +## °Ê²¼»²¾È: `set polar grid`, `polar heatmap`¡£ #end 3 ÆÌÊñ¤È¥Þ¥¹¥¯¤ÈÊ¿³ê²½ (Hulls, masks, and smoothing) ?new hulls #start #b 2 ¼¡¸µ¤ÎÅÀ¤Î½¸¹ç¤ò¡¢¤½¤Î¶­³¦¤Î¿³Ñ·Á¤ÇÃÖ¤­´¹¤¨¤ë¿·¤·¤¤¥Õ¥£¥ë¥¿ -## `convexhull`¡£¤½¤Î¶­³¦¤Î¶ÊÀþ¤ò³ê¤é¤«¤Ë¤¹¤ë¤Ë¤Ï¡¢`smooth convexhull` -## ¤¬»È¤¨¤Þ¤¹¡£°Ê²¼»²¾È: `convexhull`¡£ +## `convexhull`¡£¤½¤Î¶­³¦¤Î¶ÊÀþ¤ò³ê¤é¤«¤Ë¤¹¤ë¤Ë¤Ï¡¢ +## "convexhull smooth path with filledcurves" ¤ò»È¤Ã¤ÆÅɤêÄÙ¤·Îΰè¤È¤· +## ¤ÆÉÁ²è¤¹¤ë¤³¤È¤Ç¤Ç¤­¤Þ¤¹¡£°Ê²¼»²¾È: `convexhull`¡£ #b pm3d ¶ÊÌ̤ä image ÉÁ²è¤ÎÁªÂò¤·¤¿°ìÉôʬ¤Î¤ß¤òɽ¼¨¤¹¤ë¤è¤¦¥Þ¥¹¥¯¤¹¤ë¤Î ## ¤Ë¡¢ÆÌÊñ (convex hull) ¤ä¾¤Î¿³Ñ·Á (polygon) ¤ò»ÈÍѤǤ­¤Þ¤¹¡£¿·¤·¤¤ ## ÉÁ²è¥¹¥¿¥¤¥ë `with mask` (¥Þ¥¹¥¯¤òÄêµÁ) ¤ä¡¢¥­¡¼¥ï¡¼¥É `mask` (¤½¤Î @@ -339,6 +371,38 @@ C ## `smooth kdensity`¡£ #end +3 ̾Á°ÉÕ¤­¥Ñ¥ì¥Ã¥È (Named palettes) +?new colormaps +#start +#b ¸½ºß¤Î¥Ñ¥ì¥Ã¥È¤ò¤½¤Î¸å¤ÎÍøÍѤΤ¿¤á̾Á°ÉÕ¤­¥«¥é¡¼¥Þ¥Ã¥×¤ËÊݸ¤Ç¤­¤Þ¤¹¡£ +## °Ê²¼»²¾È: `set colormap`¡£ +#b pm3d ¤È image plot ¤Ç°ÊÁ°Êݸ¤·¤¿¥Ñ¥ì¥Ã¥È¤ò̾Á°¤Ç»ØÄê¤Ç¤­¤Þ¤¹¡£ +## ¤³¤ì¤Ë¤è¤ê¡¢°ì¤Ä¤Î plot ¥³¥Þ¥ó¥É¤ÇÊ£¿ô¤Î¥Ñ¥ì¥Ã¥È¤ò»ÈÍѤǤ­¤Þ¤¹¡£ +## °Ê²¼»²¾È: `colorspec palette`¡£ +#b ̾Á°ÉÕ¤­¥Ñ¥ì¥Ã¥È¥«¥é¡¼¥Þ¥Ã¥×¤Ï¡¢32-bit ARGB ¿§ÃͤÎÇÛÎó¤È¤·¤ÆÁàºî¤Ç¤­ +## ¤Þ¤¹¡£¤³¤ì¤Ë¤è¤ê¡¢¥¢¥ë¥Õ¥¡¥Á¥ã¥Í¥ëÃͤòÄɲä·¤¿¤ê¡¢¥³¥Þ¥ó¥É +## `set palette` ¤Ç¤Ï´Êñ¤Ë»ØÄê¤Ç¤­¤Ê¤¤Â¾¤Î½¤Àµ¤ò²Äǽ¤Ë¤·¤Þ¤¹¡£ +#b ÄêµÁºÑ¤ß¤Î¿·¤·¤¤¿§µ¡¹½ `set palette viridis`¡£ +#b ¥Õ¥¡¥¤¥ë¤ä¥Ç¡¼¥¿¥Ö¥í¥Ã¥¯¤«¤éÆÉ¤ß¹þ¤ó¤À¥Ñ¥ì¥Ã¥È (`set palette file`) +## ¤Ï¡¢¼Â¿ô¤Î¿§À®Ê¬¤«¡¢24bit ·Á¼°¤Î RGB ÃͤΤ¤¤º¤ì¤«¤Ç»ØÄê¤Ç¤­¤Þ¤¹¡£ +#end + +3 ¿·¤·¤¤ÉÁ²è¥¹¥¿¥¤¥ë (New plot styles) +?new styles +#start +#b ÉÁ²è¥¹¥¿¥¤¥ë `with surface` ¤Ï¡¢2 ¼¡¸µ¶ËºÂɸ¤Çµ¡Ç½¤·¡¢ÆþÎÏÅÀ¤ÎǤ°Õ¤Î +## ½¸¹ç¤«¤é¤Î½Å¤ßÉÕ¤±¤Î´óÍ¿¤Ë¤è¤ê¿§ÉÕ¤±¤µ¤ì¤¿Ê¿Ì̤ο§Åɤê³Ê»Òɽ¸½¤òÀ¸À® +## ¤·¤Þ¤¹¡£¤³¤ì¤Ï¡¢3 ¼¡¸µ³Ê»Ò¶ÊÌ̤òÉÁ²è¥¹¥¿¥¤¥ë `with pm3d` ¤È `dgrid3d` +## ¤ÇÀ¸À®¤¹¤ë¤³¤È¤ÎÎà»÷¤Ç¤¹¡£ +## °Ê²¼»²¾È: `set polar grid`, `polar heatmap`¡£ +#b ÉÁ²è¥¹¥¿¥¤¥ë `with lines` ¤Ë¤Ï¸½ºß¥Õ¥£¥ë¥¿¥ª¥×¥·¥ç¥ó `sharpen` ¤¬¤¢ +## ¤ê¤Þ¤¹¡£¤³¤Î¥Õ¥£¥ë¥¿¤Ï¡¢´Ø¿ôÉÁ²è¤Ç¥¹¥Ñ¥¤¥¯¤ò¸¡½Ð¤·¤Þ¤¹¡£¤·¤«¤·¤½¤Î¥Ô +## ¡¼¥¯¤Ï´Ø¿ô¤«¤éɸËܤȤ·¤Æ¼è¤Ã¤¿ 2 ¤Ä¤Î x ºÂɸ¤Î´Ö¤Ë¤¢¤ë¤¿¤á¡¢½ÐÎÏ¤Ç¤Ï +## ÉÔ´°Á´¤ËÀÚ¤ê¼è¤é¤ì¤Æ¤·¤Þ¤¤¤Þ¤¹¡£¤³¤Î¥Õ¥£¥ë¥¿¤Ï¡¢¤½¤Î¤è¤¦¤Ê¥Ô¡¼¥¯ÅÀ¤Î +## ¾ì½ê¤Ë¿·¤·¤¤¥µ¥ó¥×¥ëÅÀ¤òÄɲä·¤Þ¤¹¡£ +## °Ê²¼»²¾È: `filters`¡£ +#end + 3 ¿·¤·¤¤¥Ç¡¼¥¿·Á¼° (New data formats) ?new data_formats #start @@ -374,65 +438,21 @@ C #b `stats $vgrid` ¤Ç³Ê»ÒÆâ¤Î¥Ü¥¯¥»¥ë¤ÎºÇ¾®/ºÇÂç/Ê¿¶Ñ/ɸ½àÊк¹¤òÄ´ºº #end -3 ´Ø¿ô¥Ö¥í¥Ã¥¯¤È¶É½êÊÑ¿ô (Function blocks and scoped variables) -?new function blocks - ¤³¤ÎÈǤΠgnuplot ¤Ç¤Ï¡¢É¸½àŪ¤Ê gnuplot ¥³¥Þ¥ó¥É¤Î¥Ö¥í¥Ã¥¯¤ò¸Æ¤Ó½Ð¤·¤Æ - ´Ø¿ô¤È¤·¤Æ»È¤¨¤ëµ¡Ç½¤òƳÆþ¤·¤Æ¤¤¤Þ¤¹¡£´Ø¿ô¥Ö¥í¥Ã¥¯¤Ï¡¢0 ¤«¤é 9 ¸Ä¤Î°ú - ¿ô¤ò»È¤¨¤Æ¡¢°ì¤Ä¤ÎÃͤòÊÖ¤·¤Þ¤¹¡£´Ø¿ô¥Ö¥í¥Ã¥¯¤Ï¡¢·×»»¤·¤¿¿·¤·¤¤ÃͤòÊÑ¿ô - ¤Ë³ä¤êÅö¤Æ¤¿¤ê¡¢°Û¤Ê¤ë´Ø¿ô¤ä±é»»»Ò¤ò·ë¹ç¤·¤¿¤ê¡¢Í¿¤¨¤é¤ì¤¿¥Ç¡¼¥¿¤ËÂФ¹ - ¤ë·«¤êÊÖ¤·¤Îºî¶È¤ò¹Ô¤Ã¤¿¤ê¤¹¤ë¤Î¤Ë»È¤¦¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ - ¤³¤Î»ÅÁȤߤˤϡ¢3 ¤Ä¤ÎÍ×ÁǤ¬¤¢¤ê¤Þ¤¹¡£ - °Ê²¼»²¾È: `local`, `scope`, `function blocks`, `return`¡£ -#start -#b ½¤¾þ»Ò `local` ¤Ï¡¢ÊÑ¿ô¤äÇÛÎó¤Î¥ª¥×¥·¥ç¥óÀë¸À¤Ç¡¢¤½¤Î¥¹¥³¡¼¥×¤Ï¡¢¤½ -## ¤ì¤¬½ñ¤«¤ì¤Æ¤¤¤ë¥×¥í¥°¥é¥àñ°Ì¤Î¼Â¹ÔÃæ¤Î¤ß¤ËÀ©¸Â¤µ¤ì¤Þ¤¹¡£Ã±°Ì¤È¤Ï¡¢ -## ¸½ºß¤Ï¡¢`load` ¤ä `call` ʸ¤Î¼Â¹Ôñ°Ì¡¢´Ø¿ô¥Ö¥í¥Ã¥¯É¾²Á¡¢¤½¤·¤Æ `if`, -## `else`, `do for`, `while` ¤Ë³¤¯Ã椫¤Ã¤³¤Ç°Ï¤Þ¤ì¤¿¥³¡¼¥É¥Ö¥í¥Ã¥¯Ã±°Ì -## ¤Ç¤¹¡£¶É½ê (local) ÊÑ¿ô¤Î̾Á°¤¬Âç°è (global) ÊÑ¿ô¤Î̾Á°¤È¤Ö¤Ä¤«¤ë¾ì -## ¹ç¤Ï¡¢¤½¤Î¶É½ê¥¹¥³¡¼¥×¤«¤éÈ´¤±¤ë¤Þ¤Ç¤ÏÂç°èÊÑ¿ô¤Ï±£¤µ¤ì¤Þ¤¹¡£ -#b ¥³¥Þ¥ó¥É `function` ¤Ï¡¢gnuplot ¥³¥Þ¥ó¥É¤«¤é¤Ê¤ë̾Á°ÉÕ¤­´Ø¿ô¥Ö¥í¥Ã¥¯ -## (¼ÂºÝ¤Ï¤¢¤ëʸ»úÎó¤ÎÇÛÎó) ¤òÀë¸À¤·¤Þ¤¹¡£´Ø¿ô¥Ö¥í¥Ã¥¯¤ò¸Æ¤Ó½Ð¤¹¤È¡¢¤½ -## ¤Î¥³¥Þ¥ó¥É¤¬¡¢¥Ö¥í¥Ã¥¯¤ÎºÇ¸å¤Ë¤Ê¤ë¤«¡¢¤Þ¤¿¤Ï `return` ¥³¥Þ¥ó¥É¤ËÅö¤¿ -## ¤ë¤Þ¤Ç¡¢½ç¼¡¼Â¹Ô¤µ¤ì¤Þ¤¹¡£ -#b ¥³¥Þ¥ó¥É `return ` ¤Ï¡¢´Ø¿ô¥Ö¥í¥Ã¥¯¤Î¼Â¹Ô¤ò½ªÎ»¤·¤Þ¤¹¡£ -## ¼° ¤Îɾ²Á¤Î·ë²Ì¤¬¡¢¤½¤Î´Ø¿ô¤ÎÃͤȤ·¤ÆÊÖ¤µ¤ì¤Þ¤¹¡£´Ø¿ô¥Ö -## ¥í¥Ã¥¯¤Î³°¤Ç¤Ï¡¢¤É¤³¤Ç¤â `return` ¤Ï `exit` ¤ÈƱÍÍ¤ËÆ°ºî¤·¤Þ¤¹¡£ -#end - - ¤³¤Î»ÅÁȤߤò»È¤Ã¤Æ¡¢Ã±½ã¤Ê°ì¹Ô¤Î´Ø¿ôÄêµÁ `f(x) = ...` ¤è¤ê¤â¤Ã¤ÈÊ£»¨¤Ç - ¼«ÌÀ¤Ç¤Ï¤Ê¤¤´Ø¿ô¤òÄêµÁ¤·¡¢ÉÁ²è¤¹¤ëÎã¤È¤·¤Æ¡¢`function_block.dem` ¤ò»² - ¾È¤·¤Æ¤¯¤À¤µ¤¤¡£ - -3 ̾Á°ÉÕ¤­¥Ñ¥ì¥Ã¥È (Named palettes) -?new colormaps -#start -#b ¸½ºß¤Î¥Ñ¥ì¥Ã¥È¤ò¤½¤Î¸å¤ÎÍøÍѤΤ¿¤á̾Á°ÉÕ¤­¥«¥é¡¼¥Þ¥Ã¥×¤ËÊݸ¤Ç¤­¤Þ¤¹¡£ -## °Ê²¼»²¾È: `set colormap`¡£ -#b pm3d ¤È image plot ¤Ç°ÊÁ°Êݸ¤·¤¿¥Ñ¥ì¥Ã¥È¤ò̾Á°¤Ç»ØÄê¤Ç¤­¤Þ¤¹¡£ -## ¤³¤ì¤Ë¤è¤ê¡¢°ì¤Ä¤Î plot ¥³¥Þ¥ó¥É¤ÇÊ£¿ô¤Î¥Ñ¥ì¥Ã¥È¤ò»ÈÍѤǤ­¤Þ¤¹¡£ -## °Ê²¼»²¾È: `colorspec palette`¡£ -#b ̾Á°ÉÕ¤­¥Ñ¥ì¥Ã¥È¥«¥é¡¼¥Þ¥Ã¥×¤Ï¡¢32-bit ARGB ¿§ÃͤÎÇÛÎó¤È¤·¤ÆÁàºî¤Ç¤­ -## ¤Þ¤¹¡£¤³¤ì¤Ë¤è¤ê¡¢¥¢¥ë¥Õ¥¡¥Á¥ã¥Í¥ëÃͤòÄɲä·¤¿¤ê¡¢¥³¥Þ¥ó¥É -## `set palette` ¤Ç¤Ï´Êñ¤Ë»ØÄê¤Ç¤­¤Ê¤¤Â¾¤Î½¤Àµ¤ò²Äǽ¤Ë¤·¤Þ¤¹¡£ -#b ÄêµÁºÑ¤ß¤Î¿·¤·¤¤¿§µ¡¹½ `set palette viridis`¡£ -#b ¥Õ¥¡¥¤¥ë¤ä¥Ç¡¼¥¿¥Ö¥í¥Ã¥¯¤«¤éÆÉ¤ß¹þ¤ó¤À¥Ñ¥ì¥Ã¥È (`set palette file`) -## ¤Ï¡¢¼Â¿ô¤Î¿§À®Ê¬¤«¡¢24bit ·Á¼°¤Î RGB ÃͤΤ¤¤º¤ì¤«¤Ç»ØÄê¤Ç¤­¤Þ¤¹¡£ -#end - 3 ¥×¥í¥°¥é¥à¤Îή¤ì¤ÎÀ©¸æ (Program control flow) ?control flow #start -#b gnuplotrc ¤ÎÀßÄêÁªÂòÍÑ¤Ë XDG ¥Ù¡¼¥¹¥Ç¥£¥ì¥¯¥È¥ê¤ò¥µ¥Ý¡¼¥È¡£gnuplot -## ¤Ï½é´ü²½¥³¥Þ¥ó¥É¤ò¡¢$HOME/.config/gnuplot/gnuplotrc (¤â¤·Â¸ºß¤¹¤ì¤Ð) -## ¤«¤éÆÉ¤ß¹þ¤ß¤Þ¤¹¡£°Ê²¼»²¾È: `environment`¡£ +#b ¿·¤·¤¤¹½Ê¸ `if ... else if ... else ...` +#b gnuplot ¤ÎÀßÄêÁªÂò¤Ç¡¢XDG ¥Ù¡¼¥¹¤Î¥Ç¥£¥ì¥¯¥È¥êÇÛÃÖ¤ò¥µ¥Ý¡¼¥È¤·¤Æ¤¤¤Þ +## ¤¹¡£gnuplot ¤Ï¡¢$XDG_CONFIG_HOME/gnuplot/gnuplotrc ¤«¤é½é´ü¥³¥Þ¥ó¥É +## ¤òÆÉ¤ß¹þ¤ß¤Þ¤¹¡£ÂÐÏÃ¥³¥Þ¥ó¥ÉÍúÎò¤Ï¡¢$XDG_STATE_HOME/gnuplot_history +## ¤ËÊݸ¤·¤Þ¤¹¡£¤³¤ì¤é¤Î¥Õ¥¡¥¤¥ë¤¬¤Ê¤¤¾ì¹ç¤Ï¡¢gnuplot ¤Î°ÊÁ°¤Î¥Ð¡¼¥¸¥ç +## ¥ó¤ÈƱÍÍ¡¢$HOME/.gnuplot ¤È $HOME/.gnuplot_history ¤ò¤½¤ì¤¾¤ì»ÈÍѤ· +## ¤Þ¤¹¡£ +#b `unset warnings` ¤Ï¡¢¥³¥ó¥½¡¼¥ë¤Ø¤Î·Ù¹ð¥á¥Ã¥»¡¼¥¸½ÐÎϤòÍÞÀ©¤·¤Þ¤¹¡£ #b ¥³¥Þ¥ó¥É "fit" ¤ËÂФ¹¤ëÎã³°½èÍý¡£fit ¥¨¥é¡¼¤¬µ¯¤­¤¿¾ì¹ç¤Ç¤â¡¢À©¸æ¤ò ## ¾ï¤ËÆþÎϤμ¡¤Î¹Ô¤ËÊÖ¤·¤Þ¤¹¡£¥¨¥é¡¼¤¬µ¯¤­¤¿¾ì¹ç¤Ï¡¢Ê֤俤Ȥ­¤Ë ## FIT_ERROR ¤¬¥¼¥í¤Ç¤Ê¤¤Ãͤˤʤê¤Þ¤¹¡£¤³¤ì¤Ï¡¢Îɤ¯¤Ê¤¤¥Õ¥£¥Ã¥Æ¥£¥ó¥°¤« ## ¤éÉüµ¢¤¹¤ë¥¹¥¯¥ê¥×¥È¤ò²Äǽ¤Ë¤·¤Þ¤¹¡£°Ê²¼»²¾È: `fit error_recovery`¡£ -#b ¥³¥Þ¥ó¥É `load` ¤È `call` ¤Ï¡¢ÆþÎÏ¥³¥Þ¥ó¥É¤ò¥Õ¥¡¥¤¥ë¤«¤éÆÉ¤àÂå¤ï¤ê¤Ë -## ¥Ç¡¼¥¿¥Ö¥í¥Ã¥¯¤«¤é¤âÆÉ¤ß¹þ¤à¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ -#b ¿·¤·¤¤¹½Ê¸ `if ... else if ... else ...` -#b `unset warnings` ¤Ï¡¢¥³¥ó¥½¡¼¥ë¤Ø¤Î·Ù¹ð¥á¥Ã¥»¡¼¥¸½ÐÎϤòÍÞÀ©¤·¤Þ¤¹¡£ #end 3 ¿·¤·¤¤½ÐÎÏ·Á¼°¤È¥ª¥×¥·¥ç¥ó (New terminals and terminal options) @@ -466,10 +486,8 @@ C ?new week-date time 2020-2021 ǯ¤Ëµ¯¤­¤¿¿··¿¥³¥í¥Ê¥¦¥£¥ë¥¹ (Covid-19) ¤ÎÁûư¤Ç¤Ï¡¢±Ö³ØÅª¥Ç ¡¼¥¿¤Î¥°¥é¥Õ²½¤Î´Ø¿´¤¬¹â¤Þ¤ê¤Þ¤·¤¿¤¬¡¢¤½¤³¤Ç¤ÏÊó¹ð¤Î´·½¬¤È¤·¤Æ¡¢¤è¤¯ - ¡Ö½µÍËÆü¡×¤ò»È¤Ã¤¿É½¤¬¼¨¤µ¤ì¤Æ¤¤¤Þ¤·¤¿¡£¤½¤·¤Æ¤³¤ì¤Ë¤è¤ê¡¢¤³¤Î´·½¬¤ËÂÐ - ¤¹¤ë gnuplot ¤Î¥µ¥Ý¡¼¥È¤ÎÉÔ­¤¬ÌÀ¤é¤«¤Ë¤Ê¤ê¡¢Æü»þ½ñ¼°¤Î %W ¤È %U ¤Î¥¨ - ¥é¡¼¤â¤ï¤«¤ê¤Þ¤·¤¿¡£¸½ºß¤³¤ì¤é¤Ï²þÁ±¤·¡¢½µÍËÆü¤â¥µ¥Ý¡¼¥È¤¹¤ë¤è¤¦¤Ë³ÈÄ¥ - ¤·¤Æ¤¢¤ê¤Þ¤¹¡£ + ¡Ö½µÍËÆü¡×¤ò»È¤Ã¤¿É½¤¬¼¨¤µ¤ì¤Æ¤¤¤Þ¤·¤¿¡£¤³¤Î´·½¬¤ËÂФ¹¤ë gnuplot ¤Î¥µ + ¥Ý¡¼¥È¤ÎÉÔ­¤Ï²þÁ±¤·¡¢½µÍËÆü¤â¥µ¥Ý¡¼¥È¤¹¤ë¤è¤¦¤Ë³ÈÄ¥¤·¤Æ¤¢¤ê¤Þ¤¹¡£ #start #b Æü»þ½ñ¼° %W ¤Ï¡¢ISO 8601 ¤Î½µÍËÆüµ¬Â§¤Ë½¾¤¦¤è¤¦¤Ë¤Ê¤ê¤Þ¤·¤¿¡£ #b Æü»þ½ñ¼° %U ¤Ï¡¢CDC/MMWR ¤Î½µÍËÆüµ¬Â§¤Ë½¾¤¦¤è¤¦¤Ë¤Ê¤ê¤Þ¤·¤¿¡£ @@ -502,427 +520,82 @@ C ## Ʊ¤¸¿§¤Ç¶­³¦¤òÉÁ¤­¤Þ¤¹¡£¤³¤ì¤Ï¡¢¸¶ÍýŪ¤Ë»ë³Ð¸ú²Ì¤Ï¤¢¤ê¤Þ¤»¤ó¤¬¡¢¤¢¤Þ ## ¤ê¤è¤¯¤Ê¤¤ pdf ¤ä postscript ¥Ó¥å¡¼¥ï¤Î¤è¤¦¤Ê¥Ç¥£¥¹¥×¥ì¥¤¥â¡¼¥É¤Ç¡¢ ## ¥¢¥ó¥Á¥¨¥¤¥ê¥¢¥¹¤Ë¤è¤ëÉû»ºÊª¤¬Æ³Æþ¤µ¤ì¤Ê¤¤¤è¤¦¤Ë¤·¤Þ¤¹¡£ -#b `set isotoropic` ¤Ï¡¢2 ¼¡¸µ¥°¥é¥Õ¤È 3 ¼¡¸µ¥°¥é¥Õ¤ÎξÊý¤Ç¡¢x, y, z ¼´ +#b `set isotropic` ¤Ï¡¢2 ¼¡¸µ¥°¥é¥Õ¤È 3 ¼¡¸µ¥°¥é¥Õ¤ÎξÊý¤Ç¡¢x, y, z ¼´ ## ¤Î¤¹¤Ù¤Æ¤Î¥¹¥±¡¼¥ë¤¬Æ±¤¸¤Ë¤Ê¤ë¤è¤¦¤Ë¥¹¥±¡¼¥ë¤ò¹ç¤ï¤»¤Þ¤¹¡£ #b Êѹ¹: ʸ»ú¤Î²óž³Ñ¤¬À°¿ô¤È¤¤¤¦À©¸Â¤Ï¤Ê¤¯¤Ê¤ê¤Þ¤·¤¿¡£ #b ÆÃÊÌ¤Ê (Èó¿ôÃͤÎ) Àþ¼ï (linetype) `lt nodraw`, `lt black`, `lt bgnd` ## °Ê²¼»²¾È: `special_linetypes`¡£ #b ¥Ç¡¼¥¿¶îư·¿¤Î histogram ¥°¥é¥Õ¤Î¿§³ä¤êÅö¤Æ¡£°Ê²¼»²¾È: -## `histgrams colors`¡£ +## `histograms colors`¡£ #b ËÞÎã (key) ¤ÎÈ¢¤Î°ÌÃ֤ϡ¢gnuplot ¤¬Â¾¤Ë¹Ô¤¦»ÅÁȤߤˤè¤ë¤É¤ó¤Ê°ÌÃÖ·è ## ¤á¤ËÂФ·¤Æ¤â¡¢¥ª¥Õ¥»¥Ã¥È¤òÍ¿¤¨¤ë¤³¤È¤Ç¼êư¤ÇÄ´À°¤Ç¤­¤Þ¤¹¡£°Ê²¼»²¾È: ## `set key offset`¡£ #end -3 ¥Ð¡¼¥¸¥ç¥ó 5.4 ¤ÇƳÆþ¤µ¤ì¤¿µ¡Ç½ -4 64 ¥Ó¥Ã¥ÈÀ°¿ô±é»»¤Î¥µ¥Ý¡¼¥È -?version_5.4 - New features in 5.4 -#start -#b ´Ä¶­¤¬¥µ¥Ý¡¼¥È¤·¤Æ¤¤¤ì¤Ð¤¹¤Ù¤Æ¤Î¼°¤È´Ø¿ô¤Îɾ²Á¤Ç 64 ¥Ó¥Ã¥ÈÀ°¿ô±é»»¤ò -## »ÈÍÑ¡£ -#b ¥æ¡¼¥¶ÀÚ¤êÂØ¤¨²Äǽ¤ÊÀ°¿ô¥ª¡¼¥Ð¡¼¥Õ¥í¡¼¤Î¸¡½Ð¤È½èÍý¡£ -## °Ê²¼»²¾È `overflow`¡£ -#end - -4 ¥Ü¥¯¥»¥ë³Ê»Ò¥Ç¡¼¥¿ (Voxel grids) - gnuplot ¤Ï¡¢¸½ºß¥Ü¥¯¥»¥ë¥Ç¡¼¥¿ (¶õ´Ö¥Ô¥¯¥»¥ë¥Ç¡¼¥¿) ¤Î 3 ¼¡¸µ³Ê»ÒÍѤΠ- Áàºî¤ò¥µ¥Ý¡¼¥È¤·¤Þ¤¹¡£ - -#start -#b `set vgrid $gridname size N` ¤Ï¥Ü¥¯¥»¥ë¤Î NxNxN ³Ê»Ò¤ò¹½À®¤·¤Þ¤¹¡£ -#b `set vxrange [vxmin:vxmax]` ¤Ï¡¢`set vyrange` ¤È `set vzrange` ¤È¶¦ -## ¤Ë¤½¤Î³Ê»Ò¤¬¶õ´Ö¤Î¤É¤ÎÎΰè¤òÀêÍ­¤¹¤ë¤«¤òÄêµÁ¤·¤Þ¤¹¡£¤³¤ì¤Ï¡¢¥°¥é¥Õ¤Î -## xyz ¤ÎÈÏ°Ï¤È¤ÏÆ±¤¸¤Ç¤â¡¢Æ±¤¸¤Ç¤Ê¤¯¤Æ¤â¹½¤¤¤Þ¤»¤ó¡£ -#b `voxel(x,y,z)` ¤ò¸Ä¡¹¤Î¥Ü¥¯¥»¥ë¤òÆÉ¤à¡¢½ñ¤¯¤¿¤á¤Î¿ô¼°¤È¤·¤Æ»È¤¨¤Þ¤¹¡£ -#b `vfill DATA_SOURCE using x:y:z:radius:()` ¤Ï¡¢¤½¤ì¤¬¥°¥é -## ¥Õ¤òÉÁ¤¯Âå¤ï¤ê¤ËÆþÎϥǡ¼¥¿¤Î³ÆÅÀ¤Î¶á¤¯¤Î¥Ü¥¯¥»¥ëÃͤòÁý²Ã¤µ¤»¤ë¤³¤È°Ê -## ³°¤Ï plot ¥³¥Þ¥ó¥É¤ÈƱÍͤ˺îÍѤ·¤Þ¤¹¡£ -#b `vgfill` ¤Ï `vfill` ¤ÎÊѼï¤Ç¡¢¥æ¡¼¥¶ºÂɸ¤ÎÂå¤ï¤ê¤Ë³Ê»ÒºÂɸ¤ò»È¤¤¤Þ¤¹¡£ -#b `vclear $gridname` ¤Ï¸ºß¤¹¤ë¥Ü¥¯¥»¥ë³Ê»Ò¤ò¤¹¤Ù¤Æ 0 ¤Ë¥ê¥»¥Ã¥È¤·¤Þ¤¹¡£ -#b ¸½ºß¤Î°ì¤Ä¡¢¤Þ¤¿¤Ï¤½¤ì°Ê¾å¤Î¥Ü¥¯¥»¥ë³Ê»Ò¤Ï¡¢using »ØÄê¤Ç `voxel` ´Ø -## ¿ô¤ò»È¤¦¤³¤È¤Ç¡¢`splot` ¥³¥Þ¥ó¥É¤Ç¿§¤ä¤½¤Î¾¤Î°À­¤ò³ä¤êÅö¤Æ¤ë¤¿¤á¤Ë -## »²¾È¤¹¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ -## ¥Ç¥â `voxel.dem` ¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£ -#b `show vgrid` ¤Ç¸½ºßÄêµÁ¤µ¤ì¤Æ¤¤¤ë¤¹¤Ù¤Æ¤Î¥Ü¥¯¥»¥ë³Ê»Ò¤Î´ðËÜŪ¤ÊÅý·× -## ¾ðÊó¤ò½ÐÎÏ¡£ -#b ¥Ü¥¯¥»¥ë³Ê»Ò¤Ï¡¢`splot` ¥³¥Þ¥ó¥É¤ÎÉÁ²è¥¹¥¿¥¤¥ë `dots`, `points`, ¤Þ -## ¤¿¤Ï `isosurface` ¤Ç¡¢¤½¤Î̾Á°¤ò»È¤Ã¤ÆÉÁ²è¤Ç¤­¤Þ¤¹¡£ -## ¥Ç¥â `vplot.dem` ¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£ -#end - -4 ¿·¤·¤¤ÉÁ²è¥¹¥¿¥¤¥ë¤ä¥¹¥¿¥¤¥ë¥ª¥×¥·¥ç¥ó -#start -#b 3 ¼¡¸µÉÁ²è¥¹¥¿¥¤¥ë `with polygons` ¤Ï¡¢¥Õ¥¡¥¤¥ë¤«¤é¿ÌÌÂΤÎÌ̥ǡ¼¥¿ -## ¤òÆÉ¤ß¹þ¤ß¤Þ¤¹¡£¤³¤ì¤Ï¡¢¶ÊÌ̤òÀ¸À®¤·¤¿¤ê¡¢Ãæ¿È¤Î¤Ä¤Þ¤Ã¤¿¥ª¥Ö¥¸¥§¥¯¥È -## ¤òºî¤ë¤Î¤ËÍøÍѤǤ­¤Þ¤¹¡£°Ê²¼»²¾È: `with polygons`¡£ -#b `splot $voxelgrid with {dots|points}` ¤Ï¡¢»ØÄꤷ¤¿ïçÃÍ¥ì¥Ù¥ë¤è¤ê¾å¤Î -## ÃͤΤ¹¤Ù¤Æ¤Î¥Ü¥¯¥»¥ë¤Ë°õ¤ò¤Ä¤±¤Þ¤¹¡£ -#b `splot $voxelgrid with isosurface` ¤Ï¡¢»ØÄꤷ¤¿ïçÃÍ¥ì¥Ù¥ë¤è¤ê¾å¤ÎÃÍ -## ¤Î¤¹¤Ù¤Æ¤Î¥Ü¥¯¥»¥ë¤òÊñ¤à¥â¥¶¥¤¥¯·¿¤Î 3 ¼¡¸µ¶ÊÌ̤òÀ¸À®¤·¤Þ¤¹¡£°Ê²¼ -## »²¾È: `isosurface`¡£ -#b ¥Ü¥¯¥»¥ë³Ê»ÒÃͤϡ¢3 ¼¡¸µÉÁ²è»þ¤Ë `using` »ØÄê¤Ç»²¾È¤Ç¤­¤Þ¤¹¡£ -#b `set spiderplot` ¤Ï¡¢¥¯¥â¤ÎÁ㥰¥é¥Õ (¥ì¡¼¥À¡¼¥Á¥ã¡¼¥È¤È¤â) ¤òÀ¸À®¤¹ -## ¤ë¿·¤·¤¤ÉÁ²è¥â¡¼¥É¤òÁªÂò¤·¤Þ¤¹¡£¤³¤ì¤ÏËܼÁŪ¤Ë¤Ï¡¢¼´¤ò½Ä¤Ëʤ٤ëÂå¤ï -## ¤ê¤ËÊü¼ÍŪ¤ËÇÛÃÖ¤·¤¿Ê¿¹ÔºÂɸ¼´ (parallel axis) ÉÁ²è¤Ç¤¹¡£ -## °Ê²¼»²¾È: `spiderplot`, `set style spiderplot`, `set paxis`¡£ -#b ÉÁ²è¥¹¥¿¥¤¥ë `with circles` ¤¬ 3D ÉÁ²è¤Ç¤â²Äǽ¤Ë¡£ -#b ÉÁ²è¥¹¥¿¥¤¥ë `with boxes` ¤¬ 3D ÉÁ²è¤Ç¤â²Äǽ¤Ë¡£ -#b 2 ¼¡¸µÉÁ²è¥¹¥¿¥¤¥ë `with arrows`¡£³ÆÌð°õ¤ò x:y:xdelta:ydelta ¤Ç¤Ê¤¯ -## x:y:length:angle ¤Ç»ØÄꤹ¤ë°Ê³°¤Ï `with vectors` ¤ÈƱ¤¸¡£ -#b splot FOO with pm3d fillcolor -#b pm3d ¶ÊÌ̤¬¸ÄÊ̤Πfillstyle¡¢ÊÌ¡¹¤Î¾å²¼¤Î fillcolor ¤ò»ý¤Æ¤ë¤è¤¦¤Ë¡£ -#b pm3d ¤Î¥ª¥×¥·¥ç¥ó `noclipcb` ¤Ï¡¢cbrange ³°¤Î¥Ñ¥ì¥Ã¥È¥«¥é¡¼ÃͤλÍÊÕ -## ·Á¤ò¡¢cbmin ¤« cbmax ¤Ë¥¯¥ê¥Ã¥×¤·¤¿¿§¤ÇÅɤ餺¡¢ÉÁ²è¤·¤Þ¤»¤ó¡£ -#b Åù¹âÀþÀþ¼ï¤Î¥«¥¹¥¿¥Þ¥¤¥º¡£°Ê²¼»²¾È: `set cntrparam`¡£ -#b ¾²Ì̤«¤é 3 ¼¡¸µ¶ÊÌ̤γѤˤĤʤ¬¤ë±ôľÀþɽ¼¨¤ò ON/OFF ¤Ç¤­¤ë¤è¤¦¤Ë¡£ -## °Ê²¼»²¾È: `set cornerpoles`¡£ -#end - -4 ¿·¤·¤¤¥Ç¡¼¥¿Á°½èÍý¥Õ¥£¥ë¥¿ -#start -#b `zsort` ¤Ï 3 ÎóÌܤÎÃÍ¤Ç 2 ¼¡¸µ¤ÎÅÀ¤ò¥½¡¼¥È¤·¤Þ¤¹¡£°Ê²¼»²¾È: `zsort`¡£ -## ¤³¤ì¤Ï¡¢¤È¤Æ¤âÂ礭¤¤¥Ç¡¼¥¿½¸¹çÆâ¤Î¾¯¤·¤ÎÆÃÊ̤ÊÅÀ¤òÁ°ÌÌ¤Ë°ÜÆ°¤·¤Æ¤½¤ì -## ¤é¤¬Ëä¤â¤ì¤Ê¤¤¤è¤¦¤Ë¤¹¤ë¤¿¤á¤Ë¤ÏÍ­ÍѤǤ¹¡£ -#end - -4 ¿·¤·¤¤¥³¥Þ¥ó¥É¤ä¥³¥Þ¥ó¥É¥ª¥×¥·¥ç¥ó -#start -#b ¥Ü¥¯¥»¥ë³Ê»Ò¥Ç¡¼¥¿ÍÑ¥³¥Þ¥ó¥É¡£°Ê²¼»²¾È: `set vgrid`, `set vxrange`, -## `vclear`, `vfill`, `vgfill`, `voxel`¡£ -#b 3D ¥°¥é¥Õ¤Ç xy, xz, yz Ê¿Ì̤òɽ¼¨¤¹¤ë¿·¤·¤¤¥ª¥×¥·¥ç¥ó¡£ -##°Ê²¼»²¾È: `set walls`, `set grid vertical`¡£ -#b `set table separator {tab|comma|"char"}` ¤Ë¤è¤ë CSV ¥Õ¥¡¥¤¥ë¤ÎÀ¸À®¡£ -##°Ê²¼»²¾È: `plot with table`¡£ -#b ¿·¤·¤¤¥ª¥×¥·¥ç¥ó `set view projection {xy|xy|yz}` ¤Ï¡¢3 ¼¡¸µ splot -##¤Î 2 ¼¡¸µ¼Í±ÆÍѤλë³Ñ¡¢¼´¤ÎÌÜÀ¹¤ê¤È¥é¥Ù¥ë¤ÎÇÛÃÖ¤òÄ´À°¤¹¤ë -##`set view projection xy` ¤Ï `set view map` ¤ÈƱÅù¡£ -#b `set rgbmax ` ¤Ë¤è¤ëÆþÎÏ RGB Ãͤβò¼á¤ÎÀ©¸æ¡£ -#b ÇÛÎó½é´üÃͤò»ØÄꤹ¤ì¤Ð¥µ¥¤¥º¤Ï°ÅÌÛ²½²Äǽ¤Ë¡£Îã: `Array A = [1,2,3]`¡£ -#b ¶ËºÂɸ¥â¡¼¥É¤Ç¤ÎÀþ¤ÎƱ¿´±ß·¿¤Î¥¯¥ê¥Ã¥Ô¥ó¥°¡£°Ê²¼»²¾È: `set clip`¡£ -#b `plot`, `splot` ¥³¥Þ¥ó¥É¤Î¥Õ¥¡¥¤¥ë̾¤«´Ø¿ô¤ò `keyentry` ¤ÇÃÖ¤­´¹¤¨¤ë -## ¤³¤È¤ÇËÞÎã¤Î¥«¥¹¥¿¥Þ¥¤¥ºÍѤÎ;ʬ¤ÊÀþ¤òÄɲòÄǽ¤Ë¡£ -##¤³¤ì¤Ï¡¢Âбþ¤¹¤ë¥°¥é¥Õ¤ÏÉÁ¤«¤º¤ËËÞÎãÃæ¤Ë¤½¤ìÍѤΠ1 ¹Ô¤òºî¤ê¤Þ¤¹¡£ -##°Ê²¼»²¾È: `keyentry`¡£ -#b ¥Þ¥¦¥¹ºÂɸÊÑ´¹´Ø¿ô¤ò¥æ¡¼¥¶»ØÄê²Ä¤Ë (»î¸³Ãʳ¬) -##map_projection ¥Ç¥â¤ò»²¾È¡£ -#b ¥³¥Þ¥ó¥É `load` ¤Ï¡¢ÆþÎÏ¥³¥Þ¥ó¥É¤ò¥Õ¥¡¥¤¥ë¤«¤éÆÉ¤ß¹þ¤àÂå¤ï¤ê¤Ë¥Ç¡¼¥¿ -## ¥Ö¥í¥Ã¥¯¤«¤é¤âÆÉ¤ß¹þ¤à¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ -#b `set datafile columnheaders` ¤Ï¡¢ÆþÎϤÎÀèÆ¬¹Ô¤ò¡¢¥Ç¡¼¥¿ÃͤǤϤʤ¯Ê¸ -## »úÎó¤È¤·¤ÆÆÉ¤Þ¤»¤Þ¤¹¡£¤³¤ì¤Ï¡¢ËÞÎã¹Ô¤ÎÀ¸À®¤Ë¤Ï±Æ¶Á¤òÍ¿¤¨¤Ê¤¤¤³¤È¤ò½ü -## ¤±¤Ð `set key autotitle columnheader` ¤ÈƱÅù¤Ç¤¹¡£¤³¤Î¥ª¥×¥·¥ç¥ó¤ÎÍ­ -## ¸ú»þ¤Ë¤Ï¡¢¥³¥Þ¥ó¥É `stats` ¤ÏÀèÆ¬¹Ô¤Îʸ»úÎó¤ÎÇÛÎó¤òÀ¸À®¤·¤Þ¤¹¡£ -#end - -4 ¿·¤·¤¤½ÐÎÏ·Á¼°¤ä½ÐÎÏ·Á¼°¥ª¥×¥·¥ç¥ó -#start -#b `pcl5` ½ÐÎÏ·Á¼°¤Ï PCL5e/PCL5c ¥×¥ê¥ó¥¿¤ÈºÇ¶á¤Î gnuplot ¤Î¤¿¤¯¤µ¤ó¤Î -##µ¡Ç½¤ò¥µ¥Ý¡¼¥È¤¹¤ë¤è¤¦¤Ë³ÈÄ¥¡£ -#b `pstricks` ½ÐÎÏ·Á¼°¤Ï¡¢RGB ¥«¥é¡¼¤äÆ©ÌÀ²½¡¢Â¿³Ñ·Á¤äÈ¢¤ÎÅɤêÄÙ¤·¤Ê¤É¡¢ -## gnuplot ¤ÎºÇ¿·¤Î¿¤¯¤Îµ¡Ç½¤ò¥µ¥Ý¡¼¥È¤¹¤ë¤è¤¦¤Ë³ÈÄ¥¤µ¤ì¤Æ¤¤¤Þ¤¹¡£ -#b ¿·¤·¤¤½ÐÎÏ·Á¼° `pict2e` ¤Ï¡¢LaTeX2e ¤Î pict2e ´Ä¶­¤Ç»ÈÍѤ¹¤ë¤â¤Î¤Ç¤¹¡£ -## ¤³¤ì¤Ï¡¢¤â¤Ï¤ä¥Ç¥Õ¥©¥ë¥È¤Ç¤Ï¥Ó¥ë¥É¤µ¤ì¤Ê¤¤¸Å¤¤½ÐÎÏ·Á¼° `latex`, -## `emtex`, `eepic`, `tpic` ¤Ëľ¤Á¤Ë¼è¤Ã¤ÆÂå¤ï¤ë¤â¤Î¤Ç¤¹¡£ -#b `texdraw` ½ÐÎÏ·Á¼°¤Ï¡¢Ç¤°Õ¤ÎÊý¸þ¤Ø¤Îʸ»úÎó¡¢²ÄÊѤÊÀþÉý¡¢¥Ð¡¼¥¸¥ç¥ó 5 -## ¤ÎÇËÀþ¡¢È¢¤ä¿³Ñ·Á¤ÎÅɤêÄÙ¤·¤ò¥µ¥Ý¡¼¥È¤¹¤ë¤è¤¦¤Ë³ÈÄ¥¤µ¤ì¤Þ¤·¤¿¡£¤³¤ì -## ¤Ï¸½ºß¤Ï plain TeX ¤Ç¤â»ÈÍѤǤ­¤Þ¤¹¡£¤³¤ì¤Ï¤¤¤Þ¤À¤Ë¥«¥é¡¼¤Ï¥µ¥Ý¡¼¥È -## ¤·¤Æ¤¤¤Þ¤»¤ó¡£ -#b `windows` ½ÐÎÏ·Á¼°¤Î¡¢½¾Íè¤Î»î¸³Åª¤Ê Direct2D ÈǤϡ¢GDI ÈÇ¤È GDI+ ÈÇ -## ¤òÃÖ¤­´¹¤¨¤Þ¤¹¡£¤³¤ì¤Ï¡¢D2D ¤òÍѤ¤¤¿°õºþ¤ä¥«¥é¡¼¥Õ¥©¥ó¥È¤Ê¤É¤ò¥µ¥Ý¡¼ -## ¥È¤·¤Æ¤¤¤Þ¤¹¡£ -#b `dospc` ¤È `svga` ¤Î DOS ÍѽÐÎÏ·Á¼°¤Ï¹¹¿·¤µ¤ì¡¢¸½ºß¤ÏÂÐÏÃŪ¤Ë¥­¡¼¥Ü -## ¡¼¥É¤ä¥Þ¥¦¥¹ÆþÎÏ (svga ¤Î¤ß) ¤â¥µ¥Ý¡¼¥È¤·¤Æ¤¤¤Þ¤¹¡£ -#end - -4 ¥ª¥Ö¥¸¥§¥¯¥È¤È¤·¤Æ¤Î¥Ô¥¯¥¹¥Þ¥Ã¥×²èÁü -#start -#b `set pixmap` ¤Ï¡¢É¸½àŪ¤Ê·Á¼° (png, jpeg, gif) ¤Î²èÁü¤ò¥Ô¥¯¥¹¥Þ¥Ã¥× -## ²èÁü¤È¤·¤Æ¼è¤ê¹þ¤ß¡¢¥°¥é¥Õ¤ä¥Ú¡¼¥¸¤ÎǤ°Õ¤Î°ÌÃÖ¤ËÇÛÃÖ¤¹¤ë¤³¤È¤ò²Äǽ¤Ë -## ¤·¤Þ¤¹¡£`with image` ¤Ë¤è¤ëÉÁ²è¤È¤Ï°ã¤¤¡¢¥Ô¥¯¥¹¥Þ¥Ã¥×¥ª¥Ö¥¸¥§¥¯¥È¤Ï -## ¸µ¡¹¤Î¥¢¥¹¥Ú¥¯¥ÈÈæ¤ä¥µ¥¤¥º¤ò¼´¤Î¥¹¥±¡¼¥ë¤ä²óž¤È¤ÏÆÈΩ¤ËÊÝ»ý¤·¤Þ¤¹¡£ -## °Ê²¼»²¾È: `pixmap`¡£ -#end +3 ¥Ð¡¼¥¸¥ç¥ó 5 ¤ÇƳÆþ¤µ¤ì¤¿µ¡Ç½¤ÎÍ×Ìó (3 Brief summary of features introduced in version 5) +?new version_5 +?version_5 -4 ¤½¤Î¾¤Î¿·¤·¤¤µ¡Ç½ +4 5.4 ¤ÇƳÆþ¤µ¤ì¤¿µ¡Ç½ (Features introduced in 5.4) +?new version_5 version_5.4 +?version_5 version_5.4 #start +#b ¿ô¼°¤È´Ø¿ô¤Ï 64 ¥Ó¥Ã¥ÈÀ°¿ô±é»»¤ò»ÈÍÑ¡£°Ê²¼»²¾È: `integer`¡£ +#b 2 ¼¡¸µÉÁ²è¥¹¥¿¥¤¥ë `polygons`, `spiderplot`, `arrows` +#b 3 ¼¡¸µÉÁ²è¥¹¥¿¥¤¥ë `boxes`, `circles`, `polygons`, `isosurface`, ¤½ +## ¤·¤Æ¤½¤Î¾¥Ü¥¯¥»¥ë³Ê»Ò¥Ç¡¼¥¿¤Îɽ¸½ +#b ¥Ç¡¼¥¿Á°½èÍý¥Õ¥£¥ë¥¿ `zsort` +#b ¥«¥¹¥¿¥Þ¥¤¥º¤·¤¿ËÞÎã (key) ¤òºîÀ®¤¹¤ë `keyentry` +#b ¤â¤Ï¤ä¥Ç¥Õ¥©¥ë¥È¤Ç¤Ï¥Ó¥ë¥É¤·¤Ê¤¤¸Å¤¤ LaTeX ·Ï½ÐÎÏ·Á¼° `latex`, +## `emtex`, `eepic`, `tpic` ¤ÎÂå¤ï¤ê¤Î½ÐÎÏ·Á¼° pict2e +#b `set pixmap` ¤Ï¡¢png/jpeg/gif ²èÁü¤ò¥Ô¥¯¥¹¥Þ¥Ã¥×²èÁü¤È¤·¤Æ¼è¤ê¹þ¤ß¡¢ +## ¥°¥é¥Õ¤ä¥Ú¡¼¥¸¤ÎǤ°Õ¤Î°ÌÃÖ¤ËÇÛÃÖ¤·¥¹¥±¡¼¥ëÊÑ´¹¤â²Äǽ #b ³Èĥʸ»úÎó¥â¡¼¥É¤Ç \U+xxxx (xxxx ¤Ï 16 ¿ÊÃͤΠ4 ¤Þ¤¿¤Ï 5 ʸ»ú) ¤Ç -##Unicode ¥³¡¼¥É¥Ý¥¤¥ó¥È¤¬»ØÄê¤Ç¤­¤ë¤è¤¦¤Ë¡£¤½¤ì¤Ï½ÐÎÏ»þ¤ËÂбþ¤¹¤ë -##UTF-8 ¥Ð¥¤¥Èʸ»úÎó¤ËÊÑ´¹¤·¤Þ¤¹¡£ -#end - -4 Êѹ¹ÅÀ (Changes) -#start -#b `pm3d filled area quadrangles` ¤Ï¡¢¸½ºß¤Î zrange ¤Ë½¾¤Ã¤Æ³ê¤é¤«¤Ë¥¯ -## ¥ê¥Ã¥Ô¥ó¥°¤·¤Þ¤¹¡£¤³¤ì¤Ï¡¢pm3d ¶ÊÌÌ¡¢¤½¤·¤Æ 3 ¼¡¸µ¤Î boxes, polygons -## Åù¤Ë¤â±Æ¶Á¤òÍ¿¤¨¤Þ¤¹¡£ -#b ÉÁ²è¥¹¥¿¥¤¥ë `with parallelaxes` ¤Î½ñ¼°¤Î²þÎÉ¡£°Ê²¼»²¾È: `parallel`¡£ -## histgram, parallelaxis, spiderplot ¥¹¥¿¥¤¥ë¤Ç¤Ï¡¢ÉÁ²èÍ×ÁǤò·«ÊÖ¤·½Ð -## ÎϤ¹¤ë½ñ¼°¤ò»ÈÍѤǤ­¤Þ¤¹: -## `plot for [column=1:N] DATA using column` -#b 2 ¼¡¸µÉÁ²è¤Ç¤Î using »ØÄê¤Ë¤è¤Ã¤ÆÆÀ¤é¤ì¤ëÊ£ÁÇ¿ôÃÍ value ¤Ï¡¢¤½¤Î¼Â¿ô -##Éôʬ real(value) ¤òɾ²Á¤¹¤ë¤Î¤Ç¤Ï¤Ê¤¯¡¢Ì¤ÄêµÁÃÍ (NaN) ¤È¤·¤Æ½èÍý¤·¤Þ -##¤¹¡£¤³¤ì¤Ï¡¢´Ø¿ô¤Î plot ¤È 3 ¼¡¸µÉÁ²è¤Ç¤Ï¾ï¤Ë¤½¤¦¤Ê¤Ã¤Æ¤¤¤Þ¤·¤¿¡£Î㤨 -##¤Ð¡¢°Ê²¼¤Î 2 ¤Ä¤Î plot ¤ÏƱ¤¸¤Ë¤Ê¤ê¤Þ¤¹¡£ -##plot [-1:1] sqrt(x); plot [-1:1] '+' using 1:(sqrt($1) -#b ¥³¥Þ¥ó¥É `set fontpath` ¤ÏÈó¿ä¾©¤Ç¤¹¡£postscript ½ÐÎÏ·Á¼°¤«¤é¤Î½ÐÎÏ -## ¤ÎÃæ¤ËËä¤á¹þ¤Þ¤ì¤ë¥Õ¥©¥ó¥È¤Î¸¡º÷¥Ñ¥¹¤Ï²þÎɤµ¤ì¤Æ¤¤¤Þ¤¹¡£ +## Unicode ¥³¡¼¥É¥Ý¥¤¥ó¥È¤¬»ØÄê¤Ç¤­¤ë¤è¤¦¤Ë¡£¤½¤ì¤Ï½ÐÎÏ»þ¤ËÂбþ¤¹¤ë +## UTF-8 ¥Ð¥¤¥Èʸ»úÎó¤ËÊÑ´¹¤·¤Þ¤¹¡£ +#b `with parallelaxes` ¤Î½ñ¼°¤Î²þÊѤˤè¤ê¡¢ÉÁ²è¥¹¥¿¥¤¥ë `histogram` ¤ä +## `spiderplot` ¤ÈƱÍÍ¤Ê plot ¥³¥Þ¥ó¥ÉÆâÉô¤Ç¤ÎÊØÍø¤Ê·«¤êÊÖ¤·¤¬²Äǽ¤Ë #end -3 ¥Ð¡¼¥¸¥ç¥ó 5.2 ¤ÇƳÆþ¤µ¤ì¤¿µ¡Ç½ (Features introduced in version 5.2) -4 ¿·¤·¤¤ÉÁ²è¥¹¥¿¥¤¥ë¤ä¥¹¥¿¥¤¥ë¥ª¥×¥·¥ç¥ó +4 5.2 ¤ÇƳÆþ¤µ¤ì¤¿µ¡Ç½ (Features introduced in 5.2) +?new version_5 version_5.2 +?version_5 version_5.2 #start -#b 3 ¼¡¸µÉÁ²è¥¹¥¿¥¤¥ë `with zerrorfill`¡£°Ê²¼»²¾È: `zerrorfill`, -## `fenceplots`¡£ -^ - zerror ¥Ç¥â -^ -## ¤â»²¾È¡£ -#b ¥Ó¡¼¥¹¥¦¥©¡¼¥à¥°¥é¥Õ¡£°Ê²¼»²¾È: `set jitter`, `beeswarm`¡£ -^ - ¥Ó¡¼¥¹¥¦¥©¡¼¥à¥°¥é¥Õ¥Ç¥â -^ -## ¤â»²¾È¡£ -#b ¥°¥é¥Õ¤ÎÅÀ (points) ¤Ç»È¤ï¤ì¤ë¸Ä¡¹¤Îµ­¹æ¤Ï¡¢¥Ç¡¼¥¿ÃͤÇÀ©¸æ¤Ç¤­¤Þ¤¹¡£ -## (°Ê²¼»²¾È: `pointtype variable`) -#end -4 ¥Ç¡¼¥¿ÍѤο·¤·¤¤Á°½èÍý¥Õ¥£¥ë¥¿ (New data pre-processing filters) -#start -#b ¥Ç¡¼¥¿½¸¹çÆâ¤Ç¤Î½Ð¸½²ó¿ô¤ÎÀµµ¬²½ (°Ê²¼»²¾È: `smooth fnormal`) +#b ÈóÀþ·ÁºÂɸ·Ï (°Ê²¼»²¾È: `set nonlinear`) #b ¥Ç¡¼¥¿¤Î³¬µéÉý³ä¤êÅö¤Æ¤Î¼«Æ°²½ (°Ê²¼»²¾È: `bins`) -#end -4 ¶ËºÂɸ¥â¡¼¥É¤Î²þÎɤȳÈÄ¥ (Polar mode improvements and extensions) -#start -#b ¥é¥Ù¥ë¡¢Ìð (arrow)¡¢¥ª¥Ö¥¸¥§¥¯¥È¤ÎÄêµÁ¤Ë¶ËºÂɸ¤¬»È¤¨¤Þ¤¹¡£ -#b `set [m]ttics` ¤Ï¶ËºÂɸ¥â¡¼¥É¤Ç¤Î³°¼þÊý°Ì¼´¤Î¥é¥Ù¥ë¤È¹ï¤ß¤òÇÛÃÖ¤·¤Þ -## ¤¹¡£ -^ - ¶ËºÂɸ¼´¤È¹ï¤ß¥é¥Ù¥ë¥Ç¥â -^ -## ¤ò»²¾È¡£ -#b `set rlabel` ¤Ïư·Â¼´ (r ¼´) ¤Î¾å¤Ë¥é¥Ù¥ë¤òÇÛÃÖ¤·¤Þ¤¹¡£ -#b µÕ¸þ¤­¤Î `rrange` (Îã: set rrange [90:0]) ¤ÇÅ·µåÃÏÊ¿ºÂɸ (celestial -## horizontal coordinates) ¤¬»È¤¨¤ë¤è¤¦¤Ë¤Ê¤ê¤Þ¤¹¡£ -^ - Å·Âε°Æ»¥Ç¥â -^ -## ¤ò»²¾È¡£ -#b `set border polar` ¤Ï¶ËºÂɸ¤Î³°¼þ¤Î²ó¤ê¤Ë¼ÂÀþ¤òÉÁ¤­¤Þ¤¹¡£ -#b `set theta` ¤Ï¶ËºÂɸ¥°¥é¥Õ¤Î³°¼þÊý°Ì¼´¤Ç¤Î theta = 0 ¤Î°ÌÃ֤ȡ¢³Ñ¤Î -## Áý²ÃÊý¸þ (»þ·×²ó¤ê¤«È¿»þ·×²ó¤ê¤«) ¤òÀ©¸æ¤·¤Þ¤¹¡£ -#end -4 ÈóÀþ·ÁºÂɸ·Ï (Nonlinear coordinates systems) -#start -#b ¥°¥é¥Õ¤ÎǤ°Õ¤Î¼´¤Ë¡¢Àþ·Á¤ÎÈϰϤؤμÌÁü¤È¤½¤ÎµÕ¼ÌÁü¤ò°ÕÌ£¤¹¤ë´Ø¿ô¤ÎÁÈ -## ¤ò³ä¤êÅö¤Æ¤ë¤³¤È¤¬¤Ç¤­¡¢¤½¤ì¤òÈóÀþ·Á¤Ë¤¹¤ë¤³¤È¤â²Äǽ¤Ç¤¹ (°Ê²¼»²¾È: -## `set nonlinear`)¡£ -^ - ÈóÀþ·Á x,y ¼´¥Ç¥â -^ -#b ¤Ê¤¸¤ß¿¼¤¤¥³¥Þ¥ó¥É `set logscale` ¤Ï¡¢¸½ºß¤Ï´Ø¿ô¤ÎÁÈ log(x), exp(x) -## ¤Ë¤è¤ëÈóÀþ·Á¼´¤ÎÎã¤Î°ì¤Ä¤È¤·¤ÆºÆ¼ÂÁõ¤µ¤ì¤Þ¤·¤¿¡£ -#end -4 ¿·¤·¤¤¥³¥Þ¥ó¥É¤ä¥³¥Þ¥ó¥É¥ª¥×¥·¥ç¥ó -#start -#b ·«¤êÊÖ¤·¼Â¹ÔÉôʬ¤ÎÃæ¥«¥Ã¥³Æâ¤Ç¤Ï¡¢`continue` ¤Ï¼¡¤Î·«¤êÊÖ¤·¤Ë¤¹¤°¤Ë -## °Üư¤·¡¢`break` ¤Ï·«¤êÊÖ¤·¤òÃæÃǤ·¤Þ¤¹¡£ -#b `toggle { | "plottitle" | all}"` ¤Ï¡¢ÂÐÏÃŪ¤Ë¸½ºß¤Î¥°¥é¥Õ¤Î -## ¹½À®Í×ÁǤòɽ¼¨¤µ¤»¤ë¤«¾Ã¤¹¤«¤òÁªÂò¤Ç¤­¤Þ¤¹¡£ -#b `save fit` ¤ÏÈó¿ä¾©¤Î¥³¥Þ¥ó¥É `update` ¤òÃÖ¤­´¹¤¨ -#b `set table "outfile.name" append` ¤Ç¡¢¤½¤Î¸å¤Î table ½ÐÎϤò¡¢´û¤Ë¸ -## ºß¤¹¤ë¥Æ¥­¥¹¥È¥Õ¥¡¥¤¥ë¤ò¾å½ñ¤­¤»¤º¡¢ÄɲýÐÎϤˤ·¤Þ¤¹¡£ -#b `set pm3d lighting` ¤Ç¡¢È¿¼Í¸÷¥Ï¥¤¥é¥¤¥È¤Ë¤è¤ëÅÀ¸÷¸»¥â¥Ç¥ë¤ò»ÈÍѤ·¤Þ -## ¤¹ (°Ê²¼»²¾È: `lighting`)¡£ -#b `set minussign` ¤Ï¡¢Éé¤Î¿ô¤Ç¤Î¥¢¥¹¥­¡¼Ê¸»ú '-' ¤ò¡¢¸½ºß¤Î¥¨¥ó¥³¡¼¥É -## ¤Ç¤ÎÆÃ¼ìʸ»ú¤ËÃÖ¤­´¹¤¨¤ë¤è¤¦ gnuplot ¤Ë»Ø¼¨¤·¤Þ¤¹¡£ -#b `set micro` ¤Ï¡¢²Ê³ØÍÑÀÜÆ¬¼­¤Î¡Ö¥Þ¥¤¥¯¥í¡×ÍѤΥ¢¥¹¥­¡¼Ê¸»ú 'u' ¤ò¡¢ -## ¸½ºß¤Î¥¨¥ó¥³¡¼¥É¤Ç¤ÎÆÃ¼ìʸ»ú¤ËÃÖ¤­´¹¤¨¤ë¤è¤¦ gnuplot ¤Ë»Ø¼¨¤·¤Þ¤¹¡£ -## micro, minussign ¤ÎÆÃ¼ì°õºþµ­¹æ¤Ï¡¢¼´¹ï¤ß¥é¥Ù¥ë¤È¡¢ÌÀ¼¨Åª¤Ë gprintf() -## ¤ÇÀ¸À®¤·¤¿Ê¸»úÎó¤Ë¤Î¤ß»ÈÍѤ·¤Þ¤¹¡£¤½¤ì¤é¤Îʸ»úɽ¸½¤Î¥Ð¥¤¥ÈÎó¤Ï¡¢¸½ºß -## ¤Î¥¨¥ó¥³¡¼¥ÉÀßÄê¤Ë°Í¸¤·¤Þ¤¹¡£ -#end -4 ¿·¤·¤¤ÇÛÎó¥Ç¡¼¥¿·¿ "array" (New data type "array") -#start -#b ¤³¤Î¥Ð¡¼¥¸¥ç¥ó¤Î gnuplot ¤Ë¤Ï¡¢¿·¤·¤¤ÇÛÎó¥Ç¡¼¥¿·¿ `array name[size]` -## ¤¬Æ³Æþ¤µ¤ì¤Æ¤¤¤Þ¤¹¡£ÇÛÎó¤Ï¡¢»ÈÍѤ¹¤ëÁ°¤ËÀë¸À¤·¤Ê¤±¤ì¤Ð¤¤¤±¤Þ¤»¤ó¡£³Æ -## ÇÛÎóÍ×ÁÇ A[i] ¤Ï¡¢Ê¸»úÎó¡¢À°¿ô¡¢¼Â¿ô¡¢Ê£ÁÇ¿ô¤Î¤¤¤º¤ì¤Ç¤â¹½¤¤¤Þ¤»¤ó¡£ -## °ì¤Ä¤ÎÇÛÎ󤬰ۤʤ뷿¤ÎÍ×ÁǤò»ý¤Ä¤³¤È¤â²Äǽ¤Ç¤¹¡£´ð¿ô±é»»»Ò |A| ¤ÏÇÛ -## Îó¤Î¥µ¥¤¥º¤òÊÖ¤·¤Þ¤¹¡£°Ê²¼»²¾È: `arrays`¡£ -#end - -4 ¿·¤·¤¤½ÐÎÏ·Á¼°¤ä½ÐÎÏ·Á¼°¥ª¥×¥·¥ç¥ó -#start -#b ¿·¤·¤¤ `sixelgd` ½ÐÎÏ·Á¼°¤Ï¡¢vt340 ¤È¸ß´¹¤ÎüËö¥¨¥ß¥å¥ì¡¼¥¿¾å¤Ç -## gnuplot ¤ò¼Â¹Ô¤·¤¿¾ì¹ç¤Ë¡¢¥°¥é¥Õ¤ò½ÐÎϤ¹¤ëÌ¿Îá¤Î¥³¥Þ¥ó¥É¥é¥¤¥ó¤Î¹ç´Ö -## ¤Ë¥°¥é¥Õ¤ò¶´¤à¤è¤¦¤Ê½ÐÎϤò¥µ¥Ý¡¼¥È¤·¤Þ¤¹¡£°Ê²¼»²¾È: `sixelgd`¡£ -#b `domterm` ½ÐÎÏ·Á¼°¤Ï¡¢svg ¤ò²ò¼á¤¹¤ëüËö¥¨¥ß¥å¥ì¡¼¥¿¾å¤Ç gnuplot ¤ò -## ¼Â¹Ô¤·¤¿¾ì¹ç¤Ë¡¢¥°¥é¥Õ¤ò½ÐÎϤ¹¤ëÌ¿Îá¤Î¥³¥Þ¥ó¥É¥é¥¤¥ó¤Î¹ç´Ö¤Ë¥°¥é¥Õ¤ò -## ¶´¤à¤è¤¦¤Ê½ÐÎϤò¥µ¥Ý¡¼¥È¤·¤Þ¤¹¡£ -#b `windows` ½ÐÎÏ·Á¼°¤Ï¡¢¸½ºß¤Î¥°¥é¥Õ¤Î¥Ó¥Ã¥È¥Þ¥Ã¥×¥Õ¥¡¥¤¥ë¤Ø¤ÎÊݸ¤ò¥µ -## ¥Ý¡¼¥È¤·¤Þ¤¹¡£ -#b `windows` ½ÐÎÏ·Á¼°¤Ï¡¢¥°¥é¥Õ¥¦¥£¥ó¥É¥¦¤È wgnuplot ¥Æ¥­¥¹¥È¥¦¥£¥¦¥ó¥É -## ¥¦¤ò¥É¥Ã¥­¥ó¥°¤Ç¤­¤Þ¤¹¡£ -#b `windows` ½ÐÎÏ·Á¼°ÍÑ (»î¸³Åª) Direct2D/DirectWrite ¿·¥Ð¥Ã¥¯¥¨¥ó¥É¡£ -#b `wxt` ½ÐÎÏ·Á¼°¤Ï¡¢Windows ¾å¤Ç¤Ï EMF ¥Õ¥¡¥¤¥ë¤Ø¤Î½ÐÎϤȥץê¥ó¥¿½ÐÎÏ -## ¤ò¥µ¥Ý¡¼¥È¡£ -#b `dumb` ½ÐÎÏ·Á¼°¤Ï¡¢Àþ¤ÈÎΰè¤ÎÅɤêÄÙ¤·¤Ç ANSI ¥«¥é¡¼¤ò¥µ¥Ý¡¼¥È¡£ -#b `tkcanvas` ½ÐÎÏ·Á¼°¤Ï¡¢¿·¤·¤¤¸À¸ì¤È¡¢ºÇ¶á¤Î gnuplot ¤Î¿¤¯¤Îµ¡Ç½¤ò¥µ -## ¥Ý¡¼¥È¤¹¤ë¤è¤¦¤Ë½ñ¤­Ä¾¤µ¤ì¤Æ¤¤¤Þ¤¹ (5.0.3 ¤è¤ê)¡£ -#end - -4 ¤½¤Î¾¤Î¿·¤·¤¤µ¡Ç½ (Other new features) -#start -#b 3 ¼¡¸µ¥°¥é¥Õ¤Î¸þ¤­¤Ë±Æ¶Á¤¹¤ëÄɲòóž³Ñ `azimuth`¡£¤³¤ì¤Ï¡¢¥³¥Þ¥ó¥É¥é -## ¥¤¥ó¤«¤é (°Ê²¼»²¾È: `set view azimuth`)¡¢¤Þ¤¿¤Ï±¦¥Þ¥¦¥¹¥Ü¥¿¥ó¤Î¥É¥é -## ¥Ã¥°¤ÇÀßÄê¤Ç¤­¤Þ¤¹¡£¥Û¥Ã¥È¥­¡¼ `z` ¤Ï azimuth ¤ò 0 ¤Ë¥ê¥»¥Ã¥È¤·¤Þ¤¹¡£ -#b Windows ¾å¤Î gnuplot ¤Ç¤Ï¡¢Unicode (BMP) ¥¹¥¯¥ê¥×¥È¤ÎÆþÎϤò¡¢ -## `set encoding` ¤Ë¤è¤ë¸½ºß¤Î¥¨¥ó¥³¡¼¥É (UTF-8 ¤ò´Þ¤à) ¤ËÊÑ´¹¤·¤Æ²ò¼á -## ¤·¤Þ¤¹¡£ -#b ʸ»úÏȤ˶­³¦¿§¤ÈÇØ·Ê¿§¤ò»ØÄê¤Ç¤­¤Þ¤¹ (°Ê²¼»²¾È: `set style textbox`) -#b ¥°¥é¥Õ¤ÎɽÂê¤Î¥«¥¹¥¿¥Þ¥¤¥º (°Ê²¼»²¾È: `plot title`, `set key`, -## `multiple keys`) -#b µ¿»÷¥Õ¥¡¥¤¥ë '+' ¤Ç¤Î¥°¥é¥Õ¤Î¥µ¥ó¥×¥ê¥ó¥°ÈϰϻØÄê¤Ë¥µ¥ó¥×¥ê¥ó¥°¶è´Ö -## ¤ò»ØÄê¤Ç¤­¤Þ¤¹¡£Îã: -## plot sample [t=0:100:10] '+' using (t):(1):(label[t]) with labels -#b µ¿»÷¥Õ¥¡¥¤¥ë '++' ¤Ï¡¢x, y ¼´¤Ç¤Ê¤¯ u, v ¼´¤Ë±è¤Ã¤¿¥µ¥ó¥×¥ê¥ó¥°¤ò¹Ô -## ¤¤¤Þ¤¹¡£¤³¤ì¤Ï¡¢3 ¼¡¸µ¥°¥é¥ÕÃæ¤Ë¡¢ÊÌ¡¹¤Î¥Ç¥«¥ë¥ÈºÂɸÎΰè¤òÀê¤á¤ë¤è¤¦ -## ¤ÊÊ£¿ô¤ÎÇÞ²ðÊÑ¿ô¶ÊÌ̤òÃÖ¤¯¤Î¤ËÊØÍø¤Ç¤·¤ç¤¦¡£ +#b 2 ¼¡¸µ¥Ó¡¼¥¹¥¦¥©¡¼¥à¥°¥é¥Õ¡£°Ê²¼»²¾È: `set jitter`¡£ +#b 3 ¼¡¸µÉÁ²è¥¹¥¿¥¤¥ë `zerrorfill` +#b 3 ¼¡¸µ¸÷¸»¥â¥Ç¥ë¤Ç±¢±Æ¤ÈÈ¿¼Í¸÷¥Ï¥¤¥é¥¤¥È¤òÄó¶¡ (°Ê²¼»²¾È: `lighting`) +#b ÇÛÎó¥Ç¡¼¥¿·¿¤È´ØÏ¢¤¹¤ë¥³¥Þ¥ó¥É¤ä±é»»»Ò¡£°Ê²¼»²¾È: `arrays`¡£ +#b ¿·¤·¤¤½ÐÎÏ·Á¼° `sizelgd`, `domterm` #b ÁêÂлþ´Ö (´Ö³ÖĹ) ¤ò½èÍý¤¹¤ë¿·¤·¤¤½ñ¼°»ØÄê»Ò tH tM tS¡£ ## °Ê²¼»²¾È: `time_specifiers`¡£ -#b ^R ¤Ç¡¢ÁȤ߹þ¤ß readline (Windows ¤Ç¤â»È¤ï¤ì¤Æ¤¤¤ë) ¤ÎÍúÎò¤ÎµÕ¸þ¤­¸¡ -## º÷¤ò³«»Ï¤·¤Þ¤¹¡£°Ê²¼»²¾È: `command-line-editing`¡£ -#b Windows ¤Ç¤Î `set output "PRN"` ¤Ë¤è¤ë°õºþ¤Î²þÎÉ¡£°Ê²¼»²¾È: -## `windows printing`¡£ #end -3 ¥Ð¡¼¥¸¥ç¥ó 5.0 ¤ÇƳÆþ¤µ¤ì¤¿µ¡Ç½ (Features introduced in version 5.0) -?Features introduced in version 5.0 +4 5.0 ¤ÇƳÆþ¤µ¤ì¤¿µ¡Ç½ (Features introduced in 5.0) +?new version_5 version_5.0 +?version_5 version_5.0 #start -#b Àþ¤ÎÅÀÀþ/ÇËÀþ¥Ñ¥¿¡¼¥ó¤Ï¡¢¸½ºß¤ÏÀþ¤Î¾¤Î°À­¤ÈÆÈΩ¤Ë»ØÄê¤Ç¤­¤Þ¤¹¡£°Ê -## ²¼»²¾È: `dashtype`, `set dashtype`, `set linetype`¡£ -#b °ì¤Ä¤Î plot ¤Ç¤ÎϢ³¤·¤¿Í×ÁǤ˻ÈÍѤµ¤ì¤ë¥Ç¥Õ¥©¥ë¥È¤Î¿§¤Î½ä²óÎó¤Ï¡¢¿§ -## ¼å¼Ô¤Ë¤è¤êÍÆ°×¤Ë¶èÊ̤Ǥ­¤ë¤â¤Î¤Ë¤Ê¤ê¤Þ¤·¤¿¡£¤½¤Î¿§¤Î½ä²óÎó¤Ï¡¢¥æ¡¼¥¶ -## ¤¬À©¸æ¤Ç¤­¤Þ¤¹ (°Ê²¼»²¾È: `set colorsequence`)¡£¤³¤Î»ÅÁȤߤϡ¢Çò¹õ¤Î -## ¥°¥é¥Õ¤òÀ¸À®¤¹¤ë¤³¤È¤Ç¤â¹Ô¤¨¤Þ¤¹ (°Ê²¼»²¾È: `set monochrome`)¡£¤Ê¤ª¡¢ -## ½¾Íè¤Î gnuplot ¤Î¥Ð¡¼¥¸¥ç¥ó¤Ç¤Ï `monochrome` ¤Ï¡¢¸½ºß¤Î½ÐÎÏ·Á¼°¤ò -## `set temrinal` ¤ÇÊѹ¹¤¹¤ë¤È¤­¤Ë¤Î¤ß¤Ë¤·¤«ÁªÂò¤Ç¤­¤Þ¤»¤ó¤Ç¤·¤¿¡£ -#b ¿·¤·¤¤ÉÁ²è¥¹¥¿¥¤¥ë `with parallelaxes`¡¢`with table`¡¢¤ª¤è¤ÓÅù¹âÀþ¤Î -## ¥é¥Ù¥ëÉÕ¤±¡£ -#b ñĴ 3 ¼¡¥¹¥×¥é¥¤¥ó¤Ë¤è¤ë¥Ç¡¼¥¿¤Î¿·¤·¤¤Á°½èÍý¥Õ¥£¥ë¥¿ (°Ê²¼»²¾È: -## `smooth mcsplines`) -#b ʸ»ú¤Î½ñ¼°À©¸æ¤Ï¡¢²¼ÉÕ¤­¡¢¾åÉÕ¤­¡¢¥Õ¥©¥ó¥È¥µ¥¤¥º¡¢¤½¤Î¾°ÊÁ°Í­¸ú¤À¤Ã -## ¤¿¤â¤Î¤Ë²Ã¤¨¡¢º£¤ÏÂÀ»úÂÎ (bold) ¤È¼ÐÂÎ (italic) ¥Õ¥©¥ó¥ÈÀßÄê¤â¥µ¥Ý¡¼ -## ¥È¤·¤Æ¤¤¤Þ¤¹¡£¤³¤Î¥â¡¼¥É (³Èĥʸ»ú½èÍý) ¤Ï¡¢¸½ºß¤Ï¥Ç¥Õ¥©¥ë¥È¤ÇÍ­¸ú¤È -## ¤Ê¤Ã¤Æ¤¤¤Þ¤¹¡£°Ê²¼»²¾È: `enhanced text`¡£Ê¸»úÎóÍ×ÁǤÏÏȤǰϤळ¤È¤â -## ¤Ç¤­¤Þ¤¹ (°Ê²¼»²¾È: `set style textbox`)¡£ -#b ÂÐÏ÷¿½ÐÎÏ·Á¼°¤Ï¡¢¥Ï¥¤¥Ñ¡¼¥Æ¥­¥¹¥È¥é¥Ù¥ë¤ò¥µ¥Ý¡¼¥È¤·¤Æ¤¤¤Þ¤¹¤¬¡¢¤³¤ì -## ¤Ï¥Þ¥¦¥¹¤¬¤½¤Î¥é¥Ù¥ë¤Î¥ê¥ó¥¯ÅÀ¾å¤Ë¤¢¤ë¤È¤­¤Ë¤Î¤ß¸½¤ì¤ë¤â¤Î¤Ç¤¹¡£ -#b ¿·¤·¤¤ºÂɸ·Ï (ÅÙ¡¢Ê¬¡¢ÉÃ)¡£°Ê²¼»²¾È: `set xtics geographic`¡£ -#b ¼´¤Î¸«½Ð¤·¤Î¥Ç¥Õ¥©¥ë¥È½ñ¼°ÍѤΠ"% h" (LaTeX ·Ï½ÐÎÏ·Á¼°¤Ç¤Ï "$%h$")¡£ -## ¤³¤Î½ñ¼°¤Ï C ¤Îɸ½à½ñ¼°¤Î %g ¤Ë»÷¤Æ¤¤¤Þ¤¹¤¬¡¢»Ø¿ôÉôʬ¤¬¤¢¤ë¾ì¹ç¤Ï¡¢ -## ¤½¤ì¤¬¾åÉÕ¤­Ê¸»ú¤È¤·¤Æ½ñ¤«¤ì¤ë¤³¤È¤¬°ã¤¤¤Þ¤¹¡£Î㤨¤Ð¡¢1.2E05 ¤Ç¤Ê¤¯ -## 1.2 x 10^5 ¤È¤Ê¤ê¤Þ¤¹¡£ -#b 32-bit ¤Î¥¢¥ë¥Õ¥¡ÃÍ + RGB ¿§É½µ­ (#AARRGGBB) ¤ò¥µ¥Ý¡¼¥È¡£°Ê²¼»²¾È: -## `colorspec`¡£ -#b hsv2rgb(H,S,V) ¤È¤¤¤¦ÊÑ´¹´Ø¿ô¤Ë¤è¤ë HSV ¿§¶õ´Ö¤Î¥µ¥Ý¡¼¥È¡£ -#b Âè 2 ¼´ (x2, y2) ¤Ï¡¢Âбþ´Ø¿ô¤Ë¤è¤ê¡¢Âè 1 ¼´¤Ë¸ÇÄê¤Ç¤­¤Þ¤¹¡£ºÇ¤âñ½ã -## ¤Ê¤Î¤Ï¡¢¤³¤ì¤Ë¤è¤êÂè 1 ¼´¤È 2 ¼´¤Î¼´¤ÎÈϰϤò°ìÃפµ¤»¤ë¤³¤È¤Ç¤¹¡£¤è¤ê -## °ìÈ̤ˡ¢¤³¤ì¤Ë¤è¤êÈóÀþ·Á¤Ê¼´¤òÄêµÁ¤Ç¤­¤ë¤è¤¦¤Ë¤Ê¤ê¤Þ¤¹¤¬¡¢¤³¤ì¤Þ¤Ç¤Ï -## ¤½¤Î¤è¤¦¤Ê¤³¤È¤ÏÂпô¼´¤·¤«¤Ç¤­¤Þ¤»¤ó¤Ç¤·¤¿¡£°Ê²¼»²¾È: `set link`¡£ -#b plot ¥³¥Þ¥ó¥É¤Î³Æ´Ø¿ô¤Ë¥ª¥×¥·¥ç¥ó¤È¤·¤ÆÉÁ²èÈϰϤòÁ°ÃÖ»ØÄê¤Ç¤­¤Þ¤¹¡£ -## ¤³¤ì¤Ï¡¢plot Á´ÂΤÎÈϰϤˤϱƶÁ¤»¤º¡¢¤½¤Î´Ø¿ô¤Î¥Ç¡¼¥¿¤ò¥µ¥ó¥×¥ê¥ó¥° -## ¤¹¤ëÈϰϤǤ·¤«¤¢¤ê¤Þ¤»¤ó¡£°Ê²¼»²¾È: `plot`, `piecewise.dem`¡£ -#b ³°Éô¥é¥¤¥Ö¥é¥ê libcerf ¤¬ÍøÍѲÄǽ¤Ç¤¢¤ì¤Ð¡¢¤½¤ì¤ÏÊ£ÁÇ¿ô³Ø´Ø¿ô cerf, -## cdawson, erfi, faddeeva, ¤ª¤è¤Ó Voigt ¥×¥í¥Õ¥¡¥¤¥ë VP(x,sigma,gamma) -## ¤òÄ󶡤¹¤ë¤Î¤Ë»È¤ï¤ì¤Þ¤¹¡£ -#b ¥³¥Þ¥ó¥É `import` ¤Ï¡¢³°Éô¶¦Í­¥ª¥Ö¥¸¥§¥¯¥È (¥µ¥Ý¡¼¥È¤Ï¥ª¥Ú¥ì¡¼¥Æ¥£¥ó -## ¥°¥·¥¹¥Æ¥à°Í¸) ¤¬Ä󶡤¹¤ë´Ø¿ô¤Ë¥æ¡¼¥¶ÄêµÁ´Ø¿ô̾¤ò³ä¤êÅö¤Æ¤Þ¤¹¡£Å¬Åö -## ¤Ê³°Éô¶¦Í­¥ª¥Ö¥¸¥§¥¯¥È¤òºî¤ë¤¿¤á¤Î¥Æ¥ó¥×¥ì¡¼¥È¥Ø¥Ã¥À¥Õ¥¡¥¤¥ë¡¢¥µ¥ó¥× -## ¥ë¥½¡¼¥¹¡¢makefile ¤Ê¤É¤¬ demo ¤ÎÃæ¤Ë¤¢¤ê¤Þ¤¹¡£ -#b ÂÐÏúî¶È¤ÎÍúÎò°ìÍ÷Æâ¤ÎľÁ°¤Î¥³¥Þ¥ó¥É¤Ï¡¢ÈÖ¹æ¤ÇºÆ¼Â¹Ô¤Ç¤­¤Þ¤¹¡£Î㤨¤Ð -## `history !5` ¤Ï¡¢`history` ¤Î°ìÍ÷Æâ¤Î 5 È֤Υ³¥Þ¥ó¥É¤òºÆ¼Â¹Ô¤·¤Þ¤¹¡£ -#b ¥Ó¥Ã¥È¥·¥Õ¥È±é»»»Ò >> ¤È <<¡£ -#b gnuplot ¤Î¥·¥§¥ë¸Æ¤Ó½Ð¤·¤Ç gnuplot ¥¹¥¯¥ê¥×¥È¤Ë¥Ñ¥é¥á¡¼¥¿¤òÅϤ»¤Þ¤¹¡£ -## gnuplot -c scriptfile.gp ARG1 ARG2 ARG3 ... +#b ½ÐÎÏ·Á¼°¤Ë°Í¸¤·¤Ê¤¤ÅÀÀþ/ÇËÀþ·¿¡£ +#b ¤Ò¤È¤Ä¤Î plot ¤Ç¤Î°ú¤­Â³¤¯ÉÁ²èÍ×ÁǤ˻ÈÍѤ¹¤ë¥Ç¥Õ¥©¥ë¥È¤Î¿§¤ÎÎó¤Ï¡¢¿§ +## ¼å¼Ô¤Ë¤è¤êÍÆ°×¤Ë¶èÊ̤Ǥ­¤ë¤â¤Î¤Ë¡£ +#b ¿·¤·¤¤ÉÁ²è¥¹¥¿¥¤¥ë `with parallelaxes`, `with table`¡£ +#b ¥Þ¥¦¥¹¤¬¤½¤Î¾å¤Ë¤¢¤ë¤È¤­¤ËÍ­¸ú¤Ë¤Ê¤ë¥Ï¥¤¥Ñ¡¼¥Æ¥­¥¹¥È¥é¥Ù¥ë¡£ +#b 2 ¼¡¸µ¡¢3 ¼¡¸µ´Ø¿ôÉÁ²è¤äµ¿»÷¥Õ¥¡¥¤¥ë '+', '++' ¤Ç¤ÎÉÁ²è¤Ë¤ª¤±¤ëÌÀ¼¨ +## Ū¤Ê¥µ¥ó¥×¥ê¥ó¥°Èϰϡ£ +#b ¿·¤·¤¤¥³¥Þ¥ó¥É `import` ¤Ë¤è¤ë¥×¥é¥°¥¤¥ó¤Î¥µ¥Ý¡¼¥È¡£³°Éô¤Î¶¦Í­¥ª¥Ö¥¸ +## ¥§¥¯¥È¤¬Ä󶡤¹¤ë´Ø¿ô¤Ë¥æ¡¼¥¶ÄêµÁ´Ø¿ô̾¤ò³ä¤êÅö¤Æ¤Þ¤¹¡£ #end -2 ¥Ð¡¼¥¸¥ç¥ó 4 ¤È 5 ¤È¤Î°ã¤¤ (Differences between versions 4 and 5) -?changes -?differences - ¥Ð¡¼¥¸¥ç¥ó 5 ¤ÇƳÆþ¤µ¤ì¤¿¤¤¤¯¤Ä¤«¤ÎÊѹ¹¤Ï¡¢Á°¤ÎÈǤΠgnuplot ÍѤΥ¹¥¯¥ê - ¥×¥È¤Îµóư¤òÊѤ¨¤ë²ÄǽÀ­¤¬¤¢¤ê¤Þ¤¹¡£ - - * NaN ¤ä¡¢Àµ¤·¤¯¤Ê¤¤¥Ç¡¼¥¿Îó¿ô¡¢¤Þ¤¿¤Ï¾¤Îͽ´ü¤·¤Ê¤¤¤â¤Î¤ò´Þ¤àÆþÎϥǡ¼ - ¥¿¤Î½èÍý¤Î²þÎÉ¡£Îã (¤ä¿Þ) ¤Ë¤Ä¤¤¤Æ¤Ï¡¢°Ê²¼»²¾È: `missing`¡£ - - * »þ´ÖºÂɸ¤Ï¡¢É¸½àŪ¤Ê Unix ¥¨¥Ý¥Ã¥¯ (1970 ǯ 1 ·î 1 Æü) ¤«¤é¤ÎÉÿô¤È - ¤·¤ÆÆâÉô¤ÇÊݸ¤·¤Þ¤¹¡£°ÊÁ°¤ÎÈǤΠgnuplot ¤Ç¤Ï¡¢Ê̤Υ¨¥Ý¥Ã¥¯ (2000 ǯ - 1 ·î 1 Æü) ¤òÆâÉô¤Ç»ÈÍѤ·¤Æ¤¤¤Þ¤·¤¿¡£¤³¤ÎÊѹ¹¤Ï¡¢gnuplot ¤Î³°¤Çºî¤é¤ì - ¤¿ÉÃñ°Ì¤Î¥Ç¡¼¥¿¤Ë¤è¤Ã¤ÆÌ·½â¤¬¤â¤¿¤é¤µ¤ì¤ëÌäÂê¤ò²ò·è¤·¤Þ¤¹¡£¥¤¥ó¥¹¥È¡¼ - ¥ë¤µ¤ì¤Æ¤¤¤ë¸Ä¡¹¤Î gnuplot ¤¬¤É¤Á¤é¤Î¥¨¥Ý¥Ã¥¯¤ò»ÈÍѤ·¤Æ¤¤¤ë¤«¤Ë¤Ä¤¤¤Æ - ¤Ï¡¢¥³¥Þ¥ó¥É `print strftime("%F",0)` ¤ÇÃΤ뤳¤È¤¬¤Ç¤­¤Þ¤¹¡£¸½ºß¤Ï¡¢»þ - ´Ö¤Ï¾¯¤Ê¤¯¤È¤â¥ß¥êÉäÎÀºÅÙ¤ÇÊݸ¤µ¤ì¤Þ¤¹¡£ - - * ´Ø¿ô `timecolumn(N,"timeformat")` ¤Ï¡¢¸½ºß¤Ï 2 ¤Ä¤Î°ú¿ô¤ò»ý¤Á¤Þ¤¹¡£ - ¿·¤·¤¤ 2 ¤ÄÌܤΰú¿ô¤Ï¤É¤Î¥Ç¡¼¥¿¼´¤È¤â´ØÏ¢¤·¤Æ¤ª¤é¤º¡¢¤è¤Ã¤Æ¤³¤ì¤Ë¤è¤ê - ´Ø¿ô `timecolumn` ¤ò¡¢x ¤ä y ¼´¤Ë»ØÄꤹ¤ë¤Î¤È¤Ï°ã¤¦·Á¼°¤ÎÆü»þ¥Ç¡¼¥¿¤Î - ÆÉ¤ß¹þ¤ß¤Ë»È¤¨¤ë¤è¤¦¤Ë¤Ê¤ê¤Þ¤¹¡£¤³¤Îµ¡Ç½¤Ï¡¢¼¡¤Î¥³¥Þ¥ó¥ÉÎó¤Ë¼è¤Ã¤ÆÊѤï - ¤ê¤Þ¤¹: `set xdata time; set timefmt "timeformat"`¡£¤³¤ì¤Ï¡¢Ê£¿ô¤Î¥Õ¥¡ - ¥¤¥ë¤«¤é°Û¤Ê¤ë½ñ¼°¤ÎÆü»þ¥Ç¡¼¥¿¤òÆÉ¤ó¤Ç¡¢¤½¤ì¤é¤òÁȤ߹ç¤ï¤»¤Æ 1 ¤Ä¤Î¥° - ¥é¥Õ¤Ë¤¹¤ë¤³¤È¤ò²Äǽ¤Ë¤·¤Þ¤¹¡£ - - * ¥³¥Þ¥ó¥É `set [axis]range` ¤Î¥­¡¼¥ï¡¼¥É `reverse` ¤Ï¡¢¼«Æ°½Ì¼Ü - (autoscaling) ¤Ë¤Î¤ß±Æ¶Á¤·¡¢`set xrange [0:1]` ¤Î¤è¤¦¤Ê¥³¥Þ¥ó¥É¤Î°ÕÌ£ - ¤òµÕ¤Ë¤·¤¿¤ê¾¤ÎÊѹ¹¤ò¹Ô¤Ã¤¿¤ê¤Ï¤·¤Þ¤»¤ó¡£¤³¤Î¤è¤¦¤Ê¾ì¹ç¤Ë x ¼´¤ÎÊý¸þ - ¤òµÕ¸þ¤­¤Ë¤·¤¿¤±¤ì¤Ð¡¢Âå¤ï¤ê¤Ë `set xrange [1:0]` ¤È¤·¤Æ¤¯¤À¤µ¤¤¡£ - - * ¥³¥Þ¥ó¥É `call` ¤Ï¡¢ÊÑ¿ô·² ARGC, ARG0, ..., ARG9 ¤òÄ󶡤·¤Þ¤¹¡£ARG0 - ¤Ï¡¢¼Â¹Ô¤¹¤ë¥¹¥¯¥ê¥×¥È̾¤ò»Ø¤·¤Þ¤¹¡£ARG1 ¤«¤é ARG9 ¤Ïʸ»úÎóÊÑ¿ô¤Ë¤Ê¤ë - ¤Î¤Ç¡¢Ä¾ÀÜ»²¾È¤¹¤ë¤«¡¢¤Þ¤¿¤ÏÎ㤨¤Ð @ARG1 ¤Î¤è¤¦¤Ë¥Þ¥¯¥íŸ³«¤µ¤»¤¿¤â¤Î - ¤ò»²¾È¤¹¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ARG0 ... ARG9 ¤ÎÆâÍÆ¤Ï¡¢Â¾¤Ë¤âÇÛÎóÊÑ¿ô ARGV - ¤ÎÍ×ÁÇ ARGV[0] ... ARGV[ARGC] ¤È¤·¤Æ¤â¼èÆÀ¤Ç¤­¤Þ¤¹¡£¸Å¤¤ gnuplot ¤Ç¤Î - call ¤Î¥Ñ¥é¥á¡¼¥¿»²¾È·Á¼° $0 ... $9 ¤Ï vergion 5 ¤Ç¤ÏÈó¿ä¾©¤Ç¤¹¡£ - - * ¥ª¥×¥·¥ç¥ó smooth ¤Î kdensity ¤Î¡¢bandwidth ¤ÎÄɲûØÄê¤Ç¤Ï¡¢¥Ç¡¼¥¿Îó - ¤«¤é¤Ç¤Ê¤¯ 1 ¤Ä¤Î¥­¡¼¥ï¡¼¥É¤È¤·¤ÆÃͤò¼è¤ê¤Þ¤¹¡£°Ê²¼»²¾È: - `smooth kdensity`¡£ +2 ¥Ð¡¼¥¸¥ç¥ó 5 ¤È 6 ¤È¤Î°ã¤¤ (2 Differences between versions 5 and 6) -2 Èó¿ä¾©¤Ê½ñ¼° (Deprecated syntax) + ¥Ð¡¼¥¸¥ç¥ó 5 ¤ÇƳÆþ¤·¤¿¤¤¤¯¤Ä¤«¤ÎÊѹ¹¤Ï¡¢gnuplot ¤Î°ÊÁ°¤Î¥Ð¡¼¥¸¥ç¥óÍÑ + ¤Î¥¹¥¯¥ê¥×¥È¤ò¼ºÇÔ¤µ¤»¤ë¡¢¤Þ¤¿¤Ï°Û¤Ê¤ë¿¶Éñ¤¤¤ò¤µ¤»¤ë¤³¤È¤¬¤¢¤ê¤Þ¤·¤¿¡£ + ¥Ð¡¼¥¸¥ç¥ó 6 ¤ÇƳÆþ¤·¤¿Êѹ¹¤Ç¤Ï¡¢¤½¤¦¤¤¤¦¤³¤È¤Ï¤È¤Æ¤â¾¯¤Ê¤¤¤Ç¤¹¡£ + +3 Èó¿ä¾©¤Ê½ñ¼° (Deprecated syntax) ?deprecated syntax -?backwards compatibility -?compatibility - °ÊÁ°¤ÎÈǤǻȤï¤ì¤Æ¤¤¤¿¤¤¤¯¤Ä¤«¤Î½ñ¼°¤Ï gnuplot 4 ¤ÇÈó¿ä¾©¤È¤Ê¤ê¤Þ¤·¤¿ - ¤¬¡¢¸åÊý¸ß´¹À­¤ò»ý¤¿¤»¤ë¤¿¤á¤Î¥³¥ó¥Ñ¥¤¥ë»þ¤Î¥ª¥×¥·¥ç¥ó¤¬ÍѰդµ¤ì¤Æ¤¤¤Þ - ¤¹¡£¸Å¤¤½ñ¼°¤Î¥µ¥Ý¡¼¥È¤Ï¸½ºß¤Ïºï½ü¤µ¤ì¤Æ¤¤¤Þ¤¹¡£ - - gnuplot 4 ¤Ç¤ÏÈó¿ä¾©¤Ç¡¢¥Ð¡¼¥¸¥ç¥ó 5 ¤Ç¤Ïºï½ü: - set title "Old" 0,-1 - set data linespoints - plot 'file' thru f(x) - plot 1 2 4 # y=1 ¤Ç¤Î¿åÊ¿Àþ - update - ¸½ºß¤ÎƱÅù¤Îµ¡Ç½: - TITLE = "New" - set title TITLE offset char 0, char -1 - set style data linespoints - plot 'file' using 1:(f(column(2))) - plot 1 linetype 2 pointtype 4 - ¥Ð¡¼¥¸¥ç¥ó 5.0 ¤Ç¤ÏÈó¿ä¾©: - if (defined(VARNAME)) ... - set style increment user - call 'script' 1.23 ABC - (in script: print $0, "$1", "number of args = $#") - set fontpath - set clabel - fit control variables FIT_* - ¸½ºß¤ÎƱÅù¤Îµ¡Ç½: - if (exists("VARNAME")) ... - set linetype - call 'script' 1.23 "ABC" - (in script: print ARG1, ARG2, "number of args = ", ARGC - set cntrlabel - set fit