You can subscribe to this list here.
| 2001 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2002 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
(1) |
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
(1) |
Sep
|
Oct
(83) |
Nov
(57) |
Dec
(111) |
| 2004 |
Jan
(38) |
Feb
(121) |
Mar
(107) |
Apr
(241) |
May
(102) |
Jun
(190) |
Jul
(239) |
Aug
(158) |
Sep
(184) |
Oct
(193) |
Nov
(47) |
Dec
(68) |
| 2005 |
Jan
(190) |
Feb
(105) |
Mar
(99) |
Apr
(65) |
May
(92) |
Jun
(250) |
Jul
(197) |
Aug
(128) |
Sep
(101) |
Oct
(183) |
Nov
(186) |
Dec
(42) |
| 2006 |
Jan
(102) |
Feb
(122) |
Mar
(154) |
Apr
(196) |
May
(181) |
Jun
(281) |
Jul
(310) |
Aug
(198) |
Sep
(145) |
Oct
(188) |
Nov
(134) |
Dec
(90) |
| 2007 |
Jan
(134) |
Feb
(181) |
Mar
(157) |
Apr
(57) |
May
(81) |
Jun
(204) |
Jul
(60) |
Aug
(37) |
Sep
(17) |
Oct
(90) |
Nov
(122) |
Dec
(72) |
| 2008 |
Jan
(130) |
Feb
(108) |
Mar
(160) |
Apr
(38) |
May
(83) |
Jun
(42) |
Jul
(75) |
Aug
(16) |
Sep
(71) |
Oct
(57) |
Nov
(59) |
Dec
(152) |
| 2009 |
Jan
(73) |
Feb
(213) |
Mar
(67) |
Apr
(40) |
May
(46) |
Jun
(82) |
Jul
(73) |
Aug
(57) |
Sep
(108) |
Oct
(36) |
Nov
(153) |
Dec
(77) |
| 2010 |
Jan
(42) |
Feb
(171) |
Mar
(150) |
Apr
(6) |
May
(22) |
Jun
(34) |
Jul
(31) |
Aug
(38) |
Sep
(32) |
Oct
(59) |
Nov
(13) |
Dec
(62) |
| 2011 |
Jan
(114) |
Feb
(139) |
Mar
(126) |
Apr
(51) |
May
(53) |
Jun
(29) |
Jul
(41) |
Aug
(29) |
Sep
(35) |
Oct
(87) |
Nov
(42) |
Dec
(20) |
| 2012 |
Jan
(111) |
Feb
(66) |
Mar
(35) |
Apr
(59) |
May
(71) |
Jun
(32) |
Jul
(11) |
Aug
(48) |
Sep
(60) |
Oct
(87) |
Nov
(16) |
Dec
(38) |
| 2013 |
Jan
(5) |
Feb
(19) |
Mar
(41) |
Apr
(47) |
May
(14) |
Jun
(32) |
Jul
(18) |
Aug
(68) |
Sep
(9) |
Oct
(42) |
Nov
(12) |
Dec
(10) |
| 2014 |
Jan
(14) |
Feb
(139) |
Mar
(137) |
Apr
(66) |
May
(72) |
Jun
(142) |
Jul
(70) |
Aug
(31) |
Sep
(39) |
Oct
(98) |
Nov
(133) |
Dec
(44) |
| 2015 |
Jan
(70) |
Feb
(27) |
Mar
(36) |
Apr
(11) |
May
(15) |
Jun
(70) |
Jul
(30) |
Aug
(63) |
Sep
(18) |
Oct
(15) |
Nov
(42) |
Dec
(29) |
| 2016 |
Jan
(37) |
Feb
(48) |
Mar
(59) |
Apr
(28) |
May
(30) |
Jun
(43) |
Jul
(47) |
Aug
(14) |
Sep
(21) |
Oct
(26) |
Nov
(10) |
Dec
(2) |
| 2017 |
Jan
(26) |
Feb
(27) |
Mar
(44) |
Apr
(11) |
May
(32) |
Jun
(28) |
Jul
(75) |
Aug
(45) |
Sep
(35) |
Oct
(285) |
Nov
(99) |
Dec
(16) |
| 2018 |
Jan
(8) |
Feb
(8) |
Mar
(42) |
Apr
(35) |
May
(23) |
Jun
(12) |
Jul
(16) |
Aug
(11) |
Sep
(8) |
Oct
(16) |
Nov
(5) |
Dec
(8) |
| 2019 |
Jan
(9) |
Feb
(28) |
Mar
(4) |
Apr
(10) |
May
(7) |
Jun
(4) |
Jul
(4) |
Aug
|
Sep
(4) |
Oct
|
Nov
(23) |
Dec
(3) |
| 2020 |
Jan
(19) |
Feb
(3) |
Mar
(22) |
Apr
(17) |
May
(10) |
Jun
(69) |
Jul
(18) |
Aug
(23) |
Sep
(25) |
Oct
(11) |
Nov
(20) |
Dec
(9) |
| 2021 |
Jan
(1) |
Feb
(7) |
Mar
(9) |
Apr
|
May
(1) |
Jun
(8) |
Jul
(6) |
Aug
(8) |
Sep
(7) |
Oct
|
Nov
(2) |
Dec
(23) |
| 2022 |
Jan
(23) |
Feb
(9) |
Mar
(9) |
Apr
|
May
(8) |
Jun
(1) |
Jul
(6) |
Aug
(8) |
Sep
(30) |
Oct
(5) |
Nov
(4) |
Dec
(6) |
| 2023 |
Jan
(2) |
Feb
(5) |
Mar
(7) |
Apr
(3) |
May
(8) |
Jun
(45) |
Jul
(8) |
Aug
|
Sep
(2) |
Oct
(14) |
Nov
(7) |
Dec
(2) |
| 2024 |
Jan
(4) |
Feb
(4) |
Mar
|
Apr
(7) |
May
(2) |
Jun
(1) |
Jul
|
Aug
(5) |
Sep
|
Oct
|
Nov
(4) |
Dec
(14) |
| 2025 |
Jan
(22) |
Feb
(6) |
Mar
(5) |
Apr
(14) |
May
(6) |
Jun
(11) |
Jul
(19) |
Aug
|
Sep
(17) |
Oct
(1) |
Nov
(2) |
Dec
(18) |
| 2026 |
Jan
|
Feb
|
Mar
(5) |
Apr
|
May
(2) |
Jun
(1) |
Jul
(6) |
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Lutz M. <lut...@gm...> - 2008-05-20 00:28:52
|
Hi Ethan,
> I've made this change in scanner.c get_num().
> It fixes the overflows on a system that handles stderr properly (linux)
> and does no worse that the previous code on a system that doesn't (sunos
> 4.1).
I just tried the current CVS build, and the problems with interactive
zooming remain, except that I don't get an error message anymore ;)
As you mentioned before, the problem is that large numbers, such as those
generated by apply_zoom() when using logarithmic axes, are not recognized
as floating point values when they do not contain a decimal point:
gnuplot> set yr[313136844993:1.8789321221e+13]
gnuplot> show yr
set yrange [ -3.95768e+08 : 1.87893e+13 ] noreverse nowriteback
This obviously doesn't work when the y-axis is logarithmic.
Changing "%.12g" to "%.12E" in apply_zoom() fixed this issue for me.
Thanks for looking into this,
Lutz
|
|
From: Shigeharu T. <sh...@ie...> - 2008-05-19 12:12:50
|
shige 05/19 2008
----------------
I will send a patch for union initialization. I cannot build
wgnuplot for gnuplot-4.3.0 by VC++ 2003 in my computer, since it
does not seem to support the union initilization by specifing the
member name (in src/gadges.h):
{.rectangle = {0, ...
This error may happen on Visual C++ 2005 Express Edition.
----- From Here -----
diff -uN src/gadgets.c.ORG src/gadgets.c
diff -uN src/gadgets.h.ORG src/gadgets.h
--- src/gadgets.h.ORG Thu May 1 16:04:58 2008
+++ src/gadgets.h Mon May 19 20:43:41 2008
@@ -434,21 +434,50 @@
#ifdef EAM_OBJECTS
/* Warning: C89 does not like the union initializers */
extern struct object default_rectangle;
+/* shige */
+#if 0
#define DEFAULT_RECTANGLE_STYLE { NULL, -1, 0, OBJ_RECTANGLE, \
{FS_SOLID, 100, 0, LT_BLACK}, \
{1, LT_BACKGROUND, 0, 1.0, 0.0}, \
{.rectangle = {0, {0,0.,0.,0.}, {0,0.,0.,0.}, {0,0.,0.,0.}, {0,0.,0.,0.}}} }
+#else
+#define DEFAULT_RECTANGLE_STYLE { NULL, -1, 0, OBJ_RECTANGLE, \
+ {FS_SOLID, 100, 0, LT_BLACK}, \
+ {1, LT_BACKGROUND, 0, 1.0, 0.0}, \
+ {{0, {0,0.,0.,0.}, {0,0.,0.,0.}, {0,0.,0.,0.}, {0,0.,0.,0.}}} }
+#define DEFAULT_RECTANGLE_STYLE_M { NULL, -1, 0, OBJ_RECTANGLE, \
+ {FS_SOLID, 100, 0, LT_BLACK}, \
+ {1, LT_BACKGROUND, 0, 1.0, 0.0}}
+#define DEFAULT_RECTANGLE_STYLE_U {0, {0,0.,0.,0.}, \
+ {0,0.,0.,0.}, {0,0.,0.,0.}, {0,0.,0.,0.}}
+#endif
extern struct object default_circle;
+#if 0
#define DEFAULT_CIRCLE_STYLE { NULL, -1, 0, OBJ_CIRCLE, \
{FS_SOLID, 100, 0, LT_BLACK}, \
{1, LT_BACKGROUND, 0, 1.0, 0.0}, \
{.circle = {1, {0,0.,0.,0.}, {0,0.,0.,0.}, 0., 360. }} }
+#else
+#define DEFAULT_CIRCLE_STYLE_M { NULL, -1, 0, OBJ_CIRCLE, \
+ {FS_SOLID, 100, 0, LT_BLACK}, \
+ {1, LT_BACKGROUND, 0, 1.0, 0.0}}
+#define DEFAULT_CIRCLE_STYLE_U {1, {0,0.,0.,0.}, \
+ {0,0.,0.,0.}, 0., 360. }
+#endif
+#if 0
#define DEFAULT_ELLIPSE_STYLE { NULL, -1, 0, OBJ_CIRCLE, \
{FS_SOLID, 100, 0, LT_BLACK}, \
{1, LT_BACKGROUND, 0, 1.0, 0.0}, \
{.ellipse = {1, {0,0.,0.,0.}, {0,0.,0.,0.}, 0. }} }
+#else
+#define DEFAULT_ELLIPSE_STYLE_M { NULL, -1, 0, OBJ_CIRCLE, \
+ {FS_SOLID, 100, 0, LT_BLACK}, \
+ {1, LT_BACKGROUND, 0, 1.0, 0.0}}
+#define DEFAULT_ELLIPSE_STYLE_U {1, {0,0.,0.,0.}, \
+ {0,0.,0.,0.}, 0. }
+#endif
#endif
diff -uN src/set.c.ORG src/set.c
--- src/set.c.ORG Thu May 1 16:05:01 2008
+++ src/set.c Mon May 19 20:47:27 2008
@@ -3290,9 +3290,23 @@
static t_object *
new_object(int tag, int object_type, t_object *new)
{
+ /* shige */
+#if 0
t_object def_rect = DEFAULT_RECTANGLE_STYLE;
t_object def_ellipse = DEFAULT_ELLIPSE_STYLE;
t_object def_circle = DEFAULT_CIRCLE_STYLE;
+#else
+ t_object def_rect = DEFAULT_RECTANGLE_STYLE_M;
+ t_object def_ellipse = DEFAULT_ELLIPSE_STYLE_M;
+ t_object def_circle = DEFAULT_CIRCLE_STYLE_M;
+ t_rectangle u_def_rect = DEFAULT_RECTANGLE_STYLE_U;
+ t_circle u_def_circle = DEFAULT_CIRCLE_STYLE_U;
+ t_ellipse u_def_ellipse = DEFAULT_ELLIPSE_STYLE_U;
+
+ def_rect.o.rectangle = u_def_rect;
+ def_ellipse.o.ellipse = u_def_ellipse;
+ def_circle.o.circle = u_def_circle;
+#endif
if (!new)
new = gp_alloc(sizeof(struct object), "object");
----- To Here -----
+========================================================+
Shigeharu TAKENO NIigata Institute of Technology
kashiwazaki,Niigata 945-1195 JAPAN
sh...@ie... TEL(&FAX): +81-257-22-8161
+========================================================+
|
|
From: Tatsuro M. <tma...@ya...> - 2008-05-17 21:40:48
|
Hello Ethan I have just checked cvs repository. I found that 2008-05-17 Shigeharu Takeno <sh...@ie...> * src/win/wgnuplib.h src/win/wgraph.c src/win/winmain.c term/win.trm: Allow 'set term win ... title "foo"' to change the title displayed for the plot window. in the ChangeLog Thanks Tatsuro --- Tatsuro MATSUOKA <tma...@ya...> wrote: > Hello > > I have confirmed it. > > See: > http://www.geocities.jp/tmgpltwin/Files/Files.html > > 0005 wgplt080517.png, 19,726 bytes, 2008-05-17, Windows term title patch. > > > Hi Ethan. Please update cvs itself. > > > Regards > > Tatsuro > > --- Tatsuro MATSUOKA <tma...@ya...> wrote: > > > Hello > > > > Is it buildable on mingw? > > If so I can try for it > > Anyway I will access cvs from now. > > > > Regards > > > > Tatsuro > > > > > > --- Ethan A Merritt <merritt@u.washington.edu> wrote: > > > > > On Wednesday 14 May 2008 18:56, Shigeharu TAKENO wrote: > > > > shige 05/15 2008 > > > > ---------------- > > > > > > > > I send a patch to modify the graph window's title of the > > > > wgnuplot, which is a request on the Japanese BBS "gnuplot QandA". > > > > > > I have attached Shige's patch to an earlier request for this > > > same feature. > > > > > > It is now on the tracker as: > > > https://sourceforge.net/tracker/?func=detail&atid=302055&aid=1769857&group_id=2055 > > > > > > Could someone with a Windows build system please test that > > > it still works after my edit to make apply against current CVS? > > > > > > Ethan > > > > > > > > > > But, I am sorry that the following patch is for gnuplot-4.0.0 > > > > since I cannot build the wgnuplot for gnuplot-4.3.0 and > > > > gnuplot-4.2.X by VC++ Toolkit 2003 in my computer. > > > > > > > > ----- From Here ----- > > > > diff -uN term/win.trm.ORG term/win.trm > > > > --- term/win.trm.ORG Thu May 15 10:24:52 2008 > > > > +++ term/win.trm Thu May 15 10:36:29 2008 > > > > @@ -118,7 +118,10 @@ > > > > > > > > /* Interface routines - create list of actions for Windows */ > > > > > > > > -enum WIN_id { WIN_DEFAULT, WIN_MONOCHROME, WIN_COLOR, WIN_OTHER }; > > > > +enum WIN_id { WIN_DEFAULT, WIN_MONOCHROME, WIN_COLOR, > > > > + /* shige */ > > > > + WIN_GTITLE, > > > > + WIN_OTHER }; > > > > > > > > static struct gen_table WIN_opts[] = > > > > { > > > > @@ -126,15 +129,25 @@ > > > > { "m$onochrome", WIN_MONOCHROME }, > > > > { "c$olor", WIN_COLOR }, > > > > { "c$olour", WIN_COLOR }, > > > > + /* shige */ > > > > + { "ti$tle", WIN_GTITLE }, > > > > { NULL, WIN_OTHER } > > > > }; > > > > > > > > +/* shige */ > > > > +static char WIN_gtitle[MAXTITLELEN] = WINGRAPHTITLE; > > > > + > > > > static int WIN_last_linetype = -3; /* HBB 20000813: linetype caching */ > > > > > > > > TERM_PUBLIC void > > > > WIN_options() > > > > { > > > > struct value a; > > > > + /* shige */ > > > > + TBOOLEAN set_title=FALSE; > > > > + > > > > + /* shige */ > > > > + graphwin.Title = WIN_gtitle; > > > > > > > > while (!END_OF_COMMAND) { > > > > switch(lookup_table(&WIN_opts[0],c_token)) { > > > > @@ -142,6 +155,9 @@ > > > > graphwin.color = TRUE; > > > > strcpy(graphwin.fontname, WINFONT); > > > > graphwin.fontsize = WINFONTSIZE; > > > > + /* shige */ > > > > + graphwin.Title = WINGRAPHTITLE; > > > > + set_title = TRUE; > > > > c_token++; > > > > break; > > > > case WIN_MONOCHROME: > > > > @@ -152,6 +168,19 @@ > > > > graphwin.color = TRUE; > > > > c_token++; > > > > break; > > > > + /* shige */ > > > > + case WIN_GTITLE: > > > > + c_token++; > > > > + if (END_OF_COMMAND) > > > > + int_error(c_token, "expecting title text"); > > > > + if (isstring(c_token)) > > > > + quote_str( WIN_gtitle, c_token, MAXTITLELEN ); > > > > + else > > > > + copy_str( WIN_gtitle, c_token, MAXTITLELEN ); > > > > + c_token++; > > > > + set_title = TRUE; > > > > + graphwin.Title = WIN_gtitle; > > > > + break; > > > > case WIN_OTHER: > > > > default: > > > > if (isstring(c_token)) { > > > > @@ -174,6 +203,8 @@ > > > > > > > > if (IsWindow(graphwin.hWndGraph) && IsIconic(graphwin.hWndGraph)) > > > > ShowWindow(graphwin.hWndGraph, SW_SHOWNORMAL); > > > > + /* shige */ > > > > + if (set_title) GraphChangeTitle(&graphwin); > > > > > > > > GraphRedraw(&graphwin); > > > > } > > > > diff -uN src/win/wgnuplib.h.ORG src/win/wgnuplib.h > > > > --- src/win/wgnuplib.h.ORG Thu May 15 10:23:46 2008 > > > > +++ src/win/wgnuplib.h Thu May 15 10:31:16 2008 > > > > @@ -344,6 +344,10 @@ > > > > #define WIN30FONT "Courier" > > > > #define WINFONT "Arial" > > > > > > > > +/* shige */ > > > > +#define MAXTITLELEN 120 > > > > +#define WINGRAPHTITLE "gnuplot graph" > > > > + > > > > #if 0 > > > > enum JUSTIFY { > > > > LEFT, CENTRE, RIGHT > > > > @@ -354,6 +358,8 @@ > > > > void WDPROC GraphClose(LPGW lpgw); > > > > void WDPROC GraphStart(LPGW lpgw, double pointsize); > > > > void WDPROC GraphEnd(LPGW lpgw); > > > > +/* shige */ > > > > +void WDPROC GraphChangeTitle(LPGW lpgw); > > > > void WDPROC GraphResume(LPGW lpgw); > > > > void WDPROC GraphOp(LPGW lpgw, WORD op, WORD x, WORD y, LPCSTR str); > > > > void WDPROC GraphPrint(LPGW lpgw); > > > > diff -uN src/win/wgraph.c.ORG src/win/wgraph.c > > > > --- src/win/wgraph.c.ORG Thu May 15 10:23:46 2008 > > > > +++ src/win/wgraph.c Thu May 15 10:32:01 2008 > > > > @@ -443,6 +443,13 @@ > > > > #endif > > > > } > > > > > > > > +/* shige */ > > > > +void WDPROC > > > > +GraphChangeTitle(LPGW lpgw) > > > > +{ > > > > + SetWindowText(lpgw->hWndGraph,lpgw->Title); > > > > +} > > > > + > > > > void WDPROC > > > > GraphResume(LPGW lpgw) > > > > { > > > > diff -uN src/win/winmain.c.ORG src/win/winmain.c > > > > --- src/win/winmain.c.ORG Thu May 15 10:23:46 2008 > > > > +++ src/win/winmain.c Thu May 15 10:33:12 2008 > > > > @@ -241,7 +241,12 @@ > > > > > > > > graphwin.hInstance = hInstance; > > > > graphwin.hPrevInstance = hPrevInstance; > > > > + /* shige */ > > > > +#if 0 > > > > graphwin.Title = "gnuplot graph"; > > > > +#else > > > > + graphwin.Title = WINGRAPHTITLE; > > > > +#endif > > > > graphwin.lptw = &textwin; > > > > graphwin.IniFile = textwin.IniFile; > > > > graphwin.IniSection = textwin.IniSection; > > > > ----- To Here ----- > > > > > > > > +========================================================+ > > > > Shigeharu TAKENO NIigata Institute of Technology > > > > kashiwazaki,Niigata 945-1195 JAPAN > > > > sh...@ie... TEL(&FAX): +81-257-22-8161 > > > > +========================================================+ > > > > > > > > ------------------------------------------------------------------------- > === 以下のメッセージは省略されました === -------------------------------------- GANBARE! NIPPON! Win your ticket to Olympic Games 2008. http://pr.mail.yahoo.co.jp/ganbare-nippon/ |
|
From: Tatsuro M. <tma...@ya...> - 2008-05-17 09:35:08
|
Hello I have confirmed it. See: http://www.geocities.jp/tmgpltwin/Files/Files.html 0005 wgplt080517.png, 19,726 bytes, 2008-05-17, Windows term title patch. Hi Ethan. Please update cvs itself. Regards Tatsuro --- Tatsuro MATSUOKA <tma...@ya...> wrote: > Hello > > Is it buildable on mingw? > If so I can try for it > Anyway I will access cvs from now. > > Regards > > Tatsuro > > > --- Ethan A Merritt <merritt@u.washington.edu> wrote: > > > On Wednesday 14 May 2008 18:56, Shigeharu TAKENO wrote: > > > shige 05/15 2008 > > > ---------------- > > > > > > I send a patch to modify the graph window's title of the > > > wgnuplot, which is a request on the Japanese BBS "gnuplot QandA". > > > > I have attached Shige's patch to an earlier request for this > > same feature. > > > > It is now on the tracker as: > > https://sourceforge.net/tracker/?func=detail&atid=302055&aid=1769857&group_id=2055 > > > > Could someone with a Windows build system please test that > > it still works after my edit to make apply against current CVS? > > > > Ethan > > > > > > > But, I am sorry that the following patch is for gnuplot-4.0.0 > > > since I cannot build the wgnuplot for gnuplot-4.3.0 and > > > gnuplot-4.2.X by VC++ Toolkit 2003 in my computer. > > > > > > ----- From Here ----- > > > diff -uN term/win.trm.ORG term/win.trm > > > --- term/win.trm.ORG Thu May 15 10:24:52 2008 > > > +++ term/win.trm Thu May 15 10:36:29 2008 > > > @@ -118,7 +118,10 @@ > > > > > > /* Interface routines - create list of actions for Windows */ > > > > > > -enum WIN_id { WIN_DEFAULT, WIN_MONOCHROME, WIN_COLOR, WIN_OTHER }; > > > +enum WIN_id { WIN_DEFAULT, WIN_MONOCHROME, WIN_COLOR, > > > + /* shige */ > > > + WIN_GTITLE, > > > + WIN_OTHER }; > > > > > > static struct gen_table WIN_opts[] = > > > { > > > @@ -126,15 +129,25 @@ > > > { "m$onochrome", WIN_MONOCHROME }, > > > { "c$olor", WIN_COLOR }, > > > { "c$olour", WIN_COLOR }, > > > + /* shige */ > > > + { "ti$tle", WIN_GTITLE }, > > > { NULL, WIN_OTHER } > > > }; > > > > > > +/* shige */ > > > +static char WIN_gtitle[MAXTITLELEN] = WINGRAPHTITLE; > > > + > > > static int WIN_last_linetype = -3; /* HBB 20000813: linetype caching */ > > > > > > TERM_PUBLIC void > > > WIN_options() > > > { > > > struct value a; > > > + /* shige */ > > > + TBOOLEAN set_title=FALSE; > > > + > > > + /* shige */ > > > + graphwin.Title = WIN_gtitle; > > > > > > while (!END_OF_COMMAND) { > > > switch(lookup_table(&WIN_opts[0],c_token)) { > > > @@ -142,6 +155,9 @@ > > > graphwin.color = TRUE; > > > strcpy(graphwin.fontname, WINFONT); > > > graphwin.fontsize = WINFONTSIZE; > > > + /* shige */ > > > + graphwin.Title = WINGRAPHTITLE; > > > + set_title = TRUE; > > > c_token++; > > > break; > > > case WIN_MONOCHROME: > > > @@ -152,6 +168,19 @@ > > > graphwin.color = TRUE; > > > c_token++; > > > break; > > > + /* shige */ > > > + case WIN_GTITLE: > > > + c_token++; > > > + if (END_OF_COMMAND) > > > + int_error(c_token, "expecting title text"); > > > + if (isstring(c_token)) > > > + quote_str( WIN_gtitle, c_token, MAXTITLELEN ); > > > + else > > > + copy_str( WIN_gtitle, c_token, MAXTITLELEN ); > > > + c_token++; > > > + set_title = TRUE; > > > + graphwin.Title = WIN_gtitle; > > > + break; > > > case WIN_OTHER: > > > default: > > > if (isstring(c_token)) { > > > @@ -174,6 +203,8 @@ > > > > > > if (IsWindow(graphwin.hWndGraph) && IsIconic(graphwin.hWndGraph)) > > > ShowWindow(graphwin.hWndGraph, SW_SHOWNORMAL); > > > + /* shige */ > > > + if (set_title) GraphChangeTitle(&graphwin); > > > > > > GraphRedraw(&graphwin); > > > } > > > diff -uN src/win/wgnuplib.h.ORG src/win/wgnuplib.h > > > --- src/win/wgnuplib.h.ORG Thu May 15 10:23:46 2008 > > > +++ src/win/wgnuplib.h Thu May 15 10:31:16 2008 > > > @@ -344,6 +344,10 @@ > > > #define WIN30FONT "Courier" > > > #define WINFONT "Arial" > > > > > > +/* shige */ > > > +#define MAXTITLELEN 120 > > > +#define WINGRAPHTITLE "gnuplot graph" > > > + > > > #if 0 > > > enum JUSTIFY { > > > LEFT, CENTRE, RIGHT > > > @@ -354,6 +358,8 @@ > > > void WDPROC GraphClose(LPGW lpgw); > > > void WDPROC GraphStart(LPGW lpgw, double pointsize); > > > void WDPROC GraphEnd(LPGW lpgw); > > > +/* shige */ > > > +void WDPROC GraphChangeTitle(LPGW lpgw); > > > void WDPROC GraphResume(LPGW lpgw); > > > void WDPROC GraphOp(LPGW lpgw, WORD op, WORD x, WORD y, LPCSTR str); > > > void WDPROC GraphPrint(LPGW lpgw); > > > diff -uN src/win/wgraph.c.ORG src/win/wgraph.c > > > --- src/win/wgraph.c.ORG Thu May 15 10:23:46 2008 > > > +++ src/win/wgraph.c Thu May 15 10:32:01 2008 > > > @@ -443,6 +443,13 @@ > > > #endif > > > } > > > > > > +/* shige */ > > > +void WDPROC > > > +GraphChangeTitle(LPGW lpgw) > > > +{ > > > + SetWindowText(lpgw->hWndGraph,lpgw->Title); > > > +} > > > + > > > void WDPROC > > > GraphResume(LPGW lpgw) > > > { > > > diff -uN src/win/winmain.c.ORG src/win/winmain.c > > > --- src/win/winmain.c.ORG Thu May 15 10:23:46 2008 > > > +++ src/win/winmain.c Thu May 15 10:33:12 2008 > > > @@ -241,7 +241,12 @@ > > > > > > graphwin.hInstance = hInstance; > > > graphwin.hPrevInstance = hPrevInstance; > > > + /* shige */ > > > +#if 0 > > > graphwin.Title = "gnuplot graph"; > > > +#else > > > + graphwin.Title = WINGRAPHTITLE; > > > +#endif > > > graphwin.lptw = &textwin; > > > graphwin.IniFile = textwin.IniFile; > > > graphwin.IniSection = textwin.IniSection; > > > ----- To Here ----- > > > > > > +========================================================+ > > > Shigeharu TAKENO NIigata Institute of Technology > > > kashiwazaki,Niigata 945-1195 JAPAN > > > sh...@ie... TEL(&FAX): +81-257-22-8161 > > > +========================================================+ > > > > > > ------------------------------------------------------------------------- > > > This SF.net email is sponsored by: Microsoft > > > Defy all challenges. Microsoft(R) Visual Studio 2008. > > > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > > > _______________________________________________ > > > gnuplot-beta mailing list > > > gnu...@li... > > > https://lists.sourceforge.net/lists/listinfo/gnuplot-beta > > > > > > > -- > > Ethan A Merritt > > Biomolecular Structure Center > > University of Washington, Seattle 98195-7742 > > > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by: Microsoft > > Defy all challenges. Microsoft(R) Visual Studio 2008. > > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > > _______________________________________________ > === 以下のメッセージは省略されました === -------------------------------------- GANBARE! NIPPON! Win your ticket to Olympic Games 2008. http://pr.mail.yahoo.co.jp/ganbare-nippon/ |
|
From: Tatsuro M. <tma...@ya...> - 2008-05-17 08:38:56
|
Hello Is it buildable on mingw? If so I can try for it Anyway I will access cvs from now. Regards Tatsuro --- Ethan A Merritt <merritt@u.washington.edu> wrote: > On Wednesday 14 May 2008 18:56, Shigeharu TAKENO wrote: > > shige 05/15 2008 > > ---------------- > > > > I send a patch to modify the graph window's title of the > > wgnuplot, which is a request on the Japanese BBS "gnuplot QandA". > > I have attached Shige's patch to an earlier request for this > same feature. > > It is now on the tracker as: > https://sourceforge.net/tracker/?func=detail&atid=302055&aid=1769857&group_id=2055 > > Could someone with a Windows build system please test that > it still works after my edit to make apply against current CVS? > > Ethan > > > > But, I am sorry that the following patch is for gnuplot-4.0.0 > > since I cannot build the wgnuplot for gnuplot-4.3.0 and > > gnuplot-4.2.X by VC++ Toolkit 2003 in my computer. > > > > ----- From Here ----- > > diff -uN term/win.trm.ORG term/win.trm > > --- term/win.trm.ORG Thu May 15 10:24:52 2008 > > +++ term/win.trm Thu May 15 10:36:29 2008 > > @@ -118,7 +118,10 @@ > > > > /* Interface routines - create list of actions for Windows */ > > > > -enum WIN_id { WIN_DEFAULT, WIN_MONOCHROME, WIN_COLOR, WIN_OTHER }; > > +enum WIN_id { WIN_DEFAULT, WIN_MONOCHROME, WIN_COLOR, > > + /* shige */ > > + WIN_GTITLE, > > + WIN_OTHER }; > > > > static struct gen_table WIN_opts[] = > > { > > @@ -126,15 +129,25 @@ > > { "m$onochrome", WIN_MONOCHROME }, > > { "c$olor", WIN_COLOR }, > > { "c$olour", WIN_COLOR }, > > + /* shige */ > > + { "ti$tle", WIN_GTITLE }, > > { NULL, WIN_OTHER } > > }; > > > > +/* shige */ > > +static char WIN_gtitle[MAXTITLELEN] = WINGRAPHTITLE; > > + > > static int WIN_last_linetype = -3; /* HBB 20000813: linetype caching */ > > > > TERM_PUBLIC void > > WIN_options() > > { > > struct value a; > > + /* shige */ > > + TBOOLEAN set_title=FALSE; > > + > > + /* shige */ > > + graphwin.Title = WIN_gtitle; > > > > while (!END_OF_COMMAND) { > > switch(lookup_table(&WIN_opts[0],c_token)) { > > @@ -142,6 +155,9 @@ > > graphwin.color = TRUE; > > strcpy(graphwin.fontname, WINFONT); > > graphwin.fontsize = WINFONTSIZE; > > + /* shige */ > > + graphwin.Title = WINGRAPHTITLE; > > + set_title = TRUE; > > c_token++; > > break; > > case WIN_MONOCHROME: > > @@ -152,6 +168,19 @@ > > graphwin.color = TRUE; > > c_token++; > > break; > > + /* shige */ > > + case WIN_GTITLE: > > + c_token++; > > + if (END_OF_COMMAND) > > + int_error(c_token, "expecting title text"); > > + if (isstring(c_token)) > > + quote_str( WIN_gtitle, c_token, MAXTITLELEN ); > > + else > > + copy_str( WIN_gtitle, c_token, MAXTITLELEN ); > > + c_token++; > > + set_title = TRUE; > > + graphwin.Title = WIN_gtitle; > > + break; > > case WIN_OTHER: > > default: > > if (isstring(c_token)) { > > @@ -174,6 +203,8 @@ > > > > if (IsWindow(graphwin.hWndGraph) && IsIconic(graphwin.hWndGraph)) > > ShowWindow(graphwin.hWndGraph, SW_SHOWNORMAL); > > + /* shige */ > > + if (set_title) GraphChangeTitle(&graphwin); > > > > GraphRedraw(&graphwin); > > } > > diff -uN src/win/wgnuplib.h.ORG src/win/wgnuplib.h > > --- src/win/wgnuplib.h.ORG Thu May 15 10:23:46 2008 > > +++ src/win/wgnuplib.h Thu May 15 10:31:16 2008 > > @@ -344,6 +344,10 @@ > > #define WIN30FONT "Courier" > > #define WINFONT "Arial" > > > > +/* shige */ > > +#define MAXTITLELEN 120 > > +#define WINGRAPHTITLE "gnuplot graph" > > + > > #if 0 > > enum JUSTIFY { > > LEFT, CENTRE, RIGHT > > @@ -354,6 +358,8 @@ > > void WDPROC GraphClose(LPGW lpgw); > > void WDPROC GraphStart(LPGW lpgw, double pointsize); > > void WDPROC GraphEnd(LPGW lpgw); > > +/* shige */ > > +void WDPROC GraphChangeTitle(LPGW lpgw); > > void WDPROC GraphResume(LPGW lpgw); > > void WDPROC GraphOp(LPGW lpgw, WORD op, WORD x, WORD y, LPCSTR str); > > void WDPROC GraphPrint(LPGW lpgw); > > diff -uN src/win/wgraph.c.ORG src/win/wgraph.c > > --- src/win/wgraph.c.ORG Thu May 15 10:23:46 2008 > > +++ src/win/wgraph.c Thu May 15 10:32:01 2008 > > @@ -443,6 +443,13 @@ > > #endif > > } > > > > +/* shige */ > > +void WDPROC > > +GraphChangeTitle(LPGW lpgw) > > +{ > > + SetWindowText(lpgw->hWndGraph,lpgw->Title); > > +} > > + > > void WDPROC > > GraphResume(LPGW lpgw) > > { > > diff -uN src/win/winmain.c.ORG src/win/winmain.c > > --- src/win/winmain.c.ORG Thu May 15 10:23:46 2008 > > +++ src/win/winmain.c Thu May 15 10:33:12 2008 > > @@ -241,7 +241,12 @@ > > > > graphwin.hInstance = hInstance; > > graphwin.hPrevInstance = hPrevInstance; > > + /* shige */ > > +#if 0 > > graphwin.Title = "gnuplot graph"; > > +#else > > + graphwin.Title = WINGRAPHTITLE; > > +#endif > > graphwin.lptw = &textwin; > > graphwin.IniFile = textwin.IniFile; > > graphwin.IniSection = textwin.IniSection; > > ----- To Here ----- > > > > +========================================================+ > > Shigeharu TAKENO NIigata Institute of Technology > > kashiwazaki,Niigata 945-1195 JAPAN > > sh...@ie... TEL(&FAX): +81-257-22-8161 > > +========================================================+ > > > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by: Microsoft > > Defy all challenges. Microsoft(R) Visual Studio 2008. > > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > > _______________________________________________ > > gnuplot-beta mailing list > > gnu...@li... > > https://lists.sourceforge.net/lists/listinfo/gnuplot-beta > > > > -- > Ethan A Merritt > Biomolecular Structure Center > University of Washington, Seattle 98195-7742 > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > gnuplot-beta mailing list > gnu...@li... > https://lists.sourceforge.net/lists/listinfo/gnuplot-beta > -------------------------------------- GANBARE! NIPPON! Win your ticket to Olympic Games 2008. http://pr.mail.yahoo.co.jp/ganbare-nippon/ |
|
From: Ethan A M. <merritt@u.washington.edu> - 2008-05-17 05:08:33
|
On Wednesday 14 May 2008 18:56, Shigeharu TAKENO wrote: > shige 05/15 2008 > ---------------- > > I send a patch to modify the graph window's title of the > wgnuplot, which is a request on the Japanese BBS "gnuplot QandA". I have attached Shige's patch to an earlier request for this same feature. It is now on the tracker as: https://sourceforge.net/tracker/?func=detail&atid=302055&aid=1769857&group_id=2055 Could someone with a Windows build system please test that it still works after my edit to make apply against current CVS? Ethan > But, I am sorry that the following patch is for gnuplot-4.0.0 > since I cannot build the wgnuplot for gnuplot-4.3.0 and > gnuplot-4.2.X by VC++ Toolkit 2003 in my computer. > > ----- From Here ----- > diff -uN term/win.trm.ORG term/win.trm > --- term/win.trm.ORG Thu May 15 10:24:52 2008 > +++ term/win.trm Thu May 15 10:36:29 2008 > @@ -118,7 +118,10 @@ > > /* Interface routines - create list of actions for Windows */ > > -enum WIN_id { WIN_DEFAULT, WIN_MONOCHROME, WIN_COLOR, WIN_OTHER }; > +enum WIN_id { WIN_DEFAULT, WIN_MONOCHROME, WIN_COLOR, > + /* shige */ > + WIN_GTITLE, > + WIN_OTHER }; > > static struct gen_table WIN_opts[] = > { > @@ -126,15 +129,25 @@ > { "m$onochrome", WIN_MONOCHROME }, > { "c$olor", WIN_COLOR }, > { "c$olour", WIN_COLOR }, > + /* shige */ > + { "ti$tle", WIN_GTITLE }, > { NULL, WIN_OTHER } > }; > > +/* shige */ > +static char WIN_gtitle[MAXTITLELEN] = WINGRAPHTITLE; > + > static int WIN_last_linetype = -3; /* HBB 20000813: linetype caching */ > > TERM_PUBLIC void > WIN_options() > { > struct value a; > + /* shige */ > + TBOOLEAN set_title=FALSE; > + > + /* shige */ > + graphwin.Title = WIN_gtitle; > > while (!END_OF_COMMAND) { > switch(lookup_table(&WIN_opts[0],c_token)) { > @@ -142,6 +155,9 @@ > graphwin.color = TRUE; > strcpy(graphwin.fontname, WINFONT); > graphwin.fontsize = WINFONTSIZE; > + /* shige */ > + graphwin.Title = WINGRAPHTITLE; > + set_title = TRUE; > c_token++; > break; > case WIN_MONOCHROME: > @@ -152,6 +168,19 @@ > graphwin.color = TRUE; > c_token++; > break; > + /* shige */ > + case WIN_GTITLE: > + c_token++; > + if (END_OF_COMMAND) > + int_error(c_token, "expecting title text"); > + if (isstring(c_token)) > + quote_str( WIN_gtitle, c_token, MAXTITLELEN ); > + else > + copy_str( WIN_gtitle, c_token, MAXTITLELEN ); > + c_token++; > + set_title = TRUE; > + graphwin.Title = WIN_gtitle; > + break; > case WIN_OTHER: > default: > if (isstring(c_token)) { > @@ -174,6 +203,8 @@ > > if (IsWindow(graphwin.hWndGraph) && IsIconic(graphwin.hWndGraph)) > ShowWindow(graphwin.hWndGraph, SW_SHOWNORMAL); > + /* shige */ > + if (set_title) GraphChangeTitle(&graphwin); > > GraphRedraw(&graphwin); > } > diff -uN src/win/wgnuplib.h.ORG src/win/wgnuplib.h > --- src/win/wgnuplib.h.ORG Thu May 15 10:23:46 2008 > +++ src/win/wgnuplib.h Thu May 15 10:31:16 2008 > @@ -344,6 +344,10 @@ > #define WIN30FONT "Courier" > #define WINFONT "Arial" > > +/* shige */ > +#define MAXTITLELEN 120 > +#define WINGRAPHTITLE "gnuplot graph" > + > #if 0 > enum JUSTIFY { > LEFT, CENTRE, RIGHT > @@ -354,6 +358,8 @@ > void WDPROC GraphClose(LPGW lpgw); > void WDPROC GraphStart(LPGW lpgw, double pointsize); > void WDPROC GraphEnd(LPGW lpgw); > +/* shige */ > +void WDPROC GraphChangeTitle(LPGW lpgw); > void WDPROC GraphResume(LPGW lpgw); > void WDPROC GraphOp(LPGW lpgw, WORD op, WORD x, WORD y, LPCSTR str); > void WDPROC GraphPrint(LPGW lpgw); > diff -uN src/win/wgraph.c.ORG src/win/wgraph.c > --- src/win/wgraph.c.ORG Thu May 15 10:23:46 2008 > +++ src/win/wgraph.c Thu May 15 10:32:01 2008 > @@ -443,6 +443,13 @@ > #endif > } > > +/* shige */ > +void WDPROC > +GraphChangeTitle(LPGW lpgw) > +{ > + SetWindowText(lpgw->hWndGraph,lpgw->Title); > +} > + > void WDPROC > GraphResume(LPGW lpgw) > { > diff -uN src/win/winmain.c.ORG src/win/winmain.c > --- src/win/winmain.c.ORG Thu May 15 10:23:46 2008 > +++ src/win/winmain.c Thu May 15 10:33:12 2008 > @@ -241,7 +241,12 @@ > > graphwin.hInstance = hInstance; > graphwin.hPrevInstance = hPrevInstance; > + /* shige */ > +#if 0 > graphwin.Title = "gnuplot graph"; > +#else > + graphwin.Title = WINGRAPHTITLE; > +#endif > graphwin.lptw = &textwin; > graphwin.IniFile = textwin.IniFile; > graphwin.IniSection = textwin.IniSection; > ----- To Here ----- > > +========================================================+ > Shigeharu TAKENO NIigata Institute of Technology > kashiwazaki,Niigata 945-1195 JAPAN > sh...@ie... TEL(&FAX): +81-257-22-8161 > +========================================================+ > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > gnuplot-beta mailing list > gnu...@li... > https://lists.sourceforge.net/lists/listinfo/gnuplot-beta > -- Ethan A Merritt Biomolecular Structure Center University of Washington, Seattle 98195-7742 |
|
From: Ethan A M. <merritt@u.washington.edu> - 2008-05-17 04:20:27
|
On Friday 16 May 2008 16:07, Ethan Merritt wrote: > On Friday 16 May 2008 15:47, Lutz Maibaum wrote: > > > > According to the manpage of my standard C library (glibc 2.6.1 release 18.3 > > for X86-64, openSUSE), atol does not check for overflow errors, whereas > > strtol does. It also has the following to say: > > > > You should not check for errors by examining the return value of > > `strtol', because the string might be a valid representation of > > `0l', `LONG_MAX', or `LONG_MIN'. Instead, check whether TAILPTR > > points to what you expect after the number (e.g. `'\0'' if the > > string should end after the number). You also need to clear ERRNO > > before the call and check it afterward, in case there was overflow. > > Yeah. To do it properly we should use strtol() instead. > > In 4.2 we switched to using strtod() and strtol() for data input. > It would make sense to do the same when reading from the command line. I've made this change in scanner.c get_num(). It fixes the overflows on a system that handles stderr properly (linux) and does no worse that the previous code on a system that doesn't (sunos 4.1). This change has the happy side effect of allowing hex constants on the command line, which makes it a whole lot easier to specify RGB colors in-line: plot 'foo' using 1:2:($3>$4 ? 0xff0000 : 0x0000ff) lc rgb variable -- Ethan A Merritt |
|
From: Ethan M. <merritt@u.washington.edu> - 2008-05-16 23:07:07
|
On Friday 16 May 2008 15:47, Lutz Maibaum wrote: > On Friday 16 May 2008 15:23:35 Ethan Merritt wrote: > > On Friday 16 May 2008 15:07, Lutz Maibaum wrote: > > > thanks for looking into this. I must admit I don't quite understand > > > your proposed changes to the scanner, but as a quick fix would it be > > > sufficient to replace the %g in the line above by %E, which always > > > includes a decimal point? > > > > That would probably fix it for the specific case of zooming, > > but the general case would still be broken. As it stands, all integer > > constants in the input stream are silently truncated to LONG_MAX on > > a "normal" machine configuration. Yours at least prints an error > > message. > > According to the manpage of my standard C library (glibc 2.6.1 release 18.3 > for X86-64, openSUSE), atol does not check for overflow errors, whereas > strtol does. It also has the following to say: > > You should not check for errors by examining the return value of > `strtol', because the string might be a valid representation of > `0l', `LONG_MAX', or `LONG_MIN'. Instead, check whether TAILPTR > points to what you expect after the number (e.g. `'\0'' if the > string should end after the number). You also need to clear ERRNO > before the call and check it afterward, in case there was overflow. Yeah. To do it properly we should use strtol() instead. In 4.2 we switched to using strtod() and strtol() for data input. It would make sense to do the same when reading from the command line. -- Ethan A Merritt |
|
From: Lutz M. <lut...@gm...> - 2008-05-16 22:47:05
|
On Friday 16 May 2008 15:23:35 Ethan Merritt wrote:
> On Friday 16 May 2008 15:07, Lutz Maibaum wrote:
> > thanks for looking into this. I must admit I don't quite understand
> > your proposed changes to the scanner, but as a quick fix would it be
> > sufficient to replace the %g in the line above by %E, which always
> > includes a decimal point?
>
> That would probably fix it for the specific case of zooming,
> but the general case would still be broken. As it stands, all integer
> constants in the input stream are silently truncated to LONG_MAX on
> a "normal" machine configuration. Yours at least prints an error
> message.
According to the manpage of my standard C library (glibc 2.6.1 release 18.3
for X86-64, openSUSE), atol does not check for overflow errors, whereas
strtol does. It also has the following to say:
You should not check for errors by examining the return value of
`strtol', because the string might be a valid representation of
`0l', `LONG_MAX', or `LONG_MIN'. Instead, check whether TAILPTR
points to what you expect after the number (e.g. `'\0'' if the
string should end after the number). You also need to clear ERRNO
before the call and check it afterward, in case there was overflow.
Thanks again,
Lutz
|
|
From: Ethan M. <merritt@u.washington.edu> - 2008-05-16 22:23:30
|
On Friday 16 May 2008 15:07, Lutz Maibaum wrote: > Hi Ethan, > > > The zoom function reads off (x1,y1) and (x2,y2) coords from the mouse > > and constructs the appropriate "set [xy]range" commands as a string > > which is fed back to the command line interpreter. In your case the > > lower bound on y is too large to represent as an integer. This would > > normally be OK because it is written using a floating point format > > > > mouse.c line 662: sprintf(s, "set xr[%.12g:%.12g]; set > > yr[%.12g:%.12g]" > > > > but since there is nothing after the decimal point, the %g format writes > > it as a 12 digit integer. Such an integer is too large to read in. It > > would work if there were a trailing decimal point, but there isn't one. > > thanks for looking into this. I must admit I don't quite understand your > proposed changes to the scanner, but as a quick fix would it be sufficient > to replace the %g in the line above by %E, which always includes a decimal > point? That would probably fix it for the specific case of zooming, but the general case would still be broken. As it stands, all integer constants in the input stream are silently truncated to LONG_MAX on a "normal" machine configuration. Yours at least prints an error message. -- Ethan A Merritt |
|
From: Lutz M. <lut...@gm...> - 2008-05-16 22:08:02
|
Hi Ethan, > The zoom function reads off (x1,y1) and (x2,y2) coords from the mouse > and constructs the appropriate "set [xy]range" commands as a string > which is fed back to the command line interpreter. In your case the > lower bound on y is too large to represent as an integer. This would > normally be OK because it is written using a floating point format > > mouse.c line 662: sprintf(s, "set xr[%.12g:%.12g]; set > yr[%.12g:%.12g]" > > but since there is nothing after the decimal point, the %g format writes > it as a 12 digit integer. Such an integer is too large to read in. It > would work if there were a trailing decimal point, but there isn't one. thanks for looking into this. I must admit I don't quite understand your proposed changes to the scanner, but as a quick fix would it be sufficient to replace the %g in the line above by %E, which always includes a decimal point? Lutz |
|
From: Ethan M. <merritt@u.washington.edu> - 2008-05-16 21:53:04
|
On Friday 16 May 2008 12:10, Lutz Maibaum wrote:
> I encountered some issues when trying to use the mouse zoom on data sets
> plotted on logarithmic axes. I have attached a sample data file. When I
> start a new gnuplot session, and plot the data using
>
> set log x; set log y; plot "test.dat" u 1:2 w lp
>
> and then try to zoom into the top right corner of the plot, there is a good
> chance that I get an error message along the lines of
>
> gnuplot> set xr[2645923.77833:105299864.051];
> set yr[525542494246:2.96579249916e+13]; set x2r[ 6.42110: 8.02058];
> set y2r[11.3442: 12.9336]
> ^
> integer overflow; change to floating point
>
> I observed this in both the X11 and the wxt terminals, using gnuplot 4.2.3
> on a linux box. Can anyone else reproduce this behavior?
No, I can't reproduce it. But I can see what is wrong from the output you gave.
The zoom function reads off (x1,y1) and (x2,y2) coords from the mouse and
constructs the appropriate "set [xy]range" commands as a string which is fed
back to the command line interpreter. In your case the lower bound on y
is too large to represent as an integer. This would normally be OK because
it is written using a floating point format
mouse.c line 662: sprintf(s, "set xr[%.12g:%.12g]; set yr[%.12g:%.12g]"
but since there is nothing after the decimal point, the %g format writes
it as a 12 digit integer. Such an integer is too large to read in. It would
work if there were a trailing decimal point, but there isn't one.
Simpler demonstation of the problem:
gnuplot> t = 525542494246
gnuplot> print t
2147483647
gnuplot> t = 525542494246.
gnuplot> print t
525542494246.0
Your machine issues the message you see
"integer overflow; change to floating point".
based on the test in scanner.c: get_num()
lval = atol(str);
if ((token[t_num].l_val.v.int_val = lval) != lval)
But this test assumes appears to assume some odd non-POSIX behavior,
and/or an odd compiler. I would expect the compiler to optimize away
the test if ((A=B) != B)
The only exception would be for A = NaN, but that can't happen for
a positive integer. My linux machine behaves as documented by the spec
for atol(). On overflow it returns MAX_LONG, which is a legal value,
and the test for ((A=MAX_LONG) != MAX_LONG) can never trigger even
if it hasn't been optimize away.
Anyhow....
Can anyone think of a down-side to simply storing the number as a complex double
in such a case? Does it even need to be treated as an int_error() rather than
a simple warning? In a case like yours, even the warning is gratuitous.
IOW, how about the following patch:
--- gnuplot/src/scanner.c 2007-08-27 01:05:18.000000000 -0700
+++ gnuplot-cvs/src/scanner.c 2008-05-16 14:37:34.000000000 -0700
@@ -278,13 +278,16 @@ get_num(char str[])
while (isdigit((unsigned char) str[++count]));
}
if (token[t_num].l_val.type == INTGR) {
- lval = atol(str);
- if ((token[t_num].l_val.v.int_val = lval) != lval)
- int_error(t_num, "integer overflow; change to floating point");
+ token[t_num].l_val.v.int_val = atol(str);
+ if (token[t_num].l_val.v.int_val < INT_MAX)
+ return(count);
+ int_warn(t_num, "integer overflow; changing to floating point");
+ token[t_num].l_val.type = CMPLX;
+ /* fall through */
}
+
+ token[t_num].l_val.v.cmplx_val.imag = 0.0;
+ token[t_num].l_val.v.cmplx_val.real = atof(str);
- } else {
- token[t_num].l_val.v.cmplx_val.imag = 0.0;
- token[t_num].l_val.v.cmplx_val.real = atof(str);
return (count);
}
--
Ethan A Merritt
|
|
From: Lutz M. <lut...@gm...> - 2008-05-16 19:10:18
|
I encountered some issues when trying to use the mouse zoom on data sets
plotted on logarithmic axes. I have attached a sample data file. When I
start a new gnuplot session, and plot the data using
set log x; set log y; plot "test.dat" u 1:2 w lp
and then try to zoom into the top right corner of the plot, there is a good
chance that I get an error message along the lines of
gnuplot> set xr[2645923.77833:105299864.051]; set
yr[525542494246:2.96579249916e+13]; set x2r[ 6.42110: 8.02058]; set y2r[
11.3442: 12.9336]
^
integer overflow; change to floating point
I observed this in both the X11 and the wxt terminals, using gnuplot 4.2.3
on a linux box. Can anyone else reproduce this behavior?
Thanks,
Lutz
|
|
From: Thomas S. <t.s...@fz...> - 2008-05-16 12:41:58
|
>> Anyway it might be reasonable to change this behavior. > > No. Changing syntax from what it has been for decades, > to match expectations of people who fail to read > documentation, is anything but reasonable. comment line continuation allows unix-users to write executable gnuplot-scripts without the need to specify the full path of the gnuplot executable: #!/bin/sh # the next line restarts using gnuplot \ exec gnuplot "$0" "$@" -- View this message in context: http://www.nabble.com/line-continuation-of-comments-tp17261745p17273789.html Sent from the Gnuplot - Dev mailing list archive at Nabble.com. |
|
From: Thomas S. <t.s...@fz...> - 2008-05-16 12:27:14
|
> Right, thanks for that the range is correct. It is possible to set the > time labels to be abbreviated month names? you had this command already in your first example: set format x "%b" > Changing the second set timefmt "%m" doesn't make any difference? timefmt specifies how data are read in. to get month-tics do: set xtics 60*60*24*31 unset mxtics -- View this message in context: http://www.nabble.com/Advice-on-boxes-plot-and-setting-xrange-with-a-time-axis-tp17228309p17273515.html Sent from the Gnuplot - Dev mailing list archive at Nabble.com. |
|
From: Tim H. <tim...@un...> - 2008-05-16 12:02:39
|
Hans-Bernhard Bröker wrote: > The way to deal with people's expectations is to write documentation for > them to read, so they'll know which expectations are correct. There's > nothing we can possibly do about the expectations of people who don't > read enough of the documentation to find "help introduction". I read this a long time ago and forgot until now. An additional remark in "help comments" would have helped. > No. Changing syntax from what it has been for decades, to match > expectations of people who fail to read documentation, is anything but > reasonable. Now, that I know that this behaviour is actually a feature, I agree. |
|
From: Hans-Bernhard B. <HBB...@t-...> - 2008-05-15 21:56:42
|
Tim Hoffmann wrote: > # this is a comment \ > this one too \ > even this > > It's not a real bug, but IMHO people would not expect > this. The way to deal with people's expectations is to write documentation for them to read, so they'll know which expectations are correct. There's nothing we can possibly do about the expectations of people who don't read enough of the documentation to find "help introduction". > This can lead to strange errors, especially for > windows users (I don't know who else would need a \ at the > end of a comment): > # load settings from d:\data\ Even windows users wouldn't _need_ that. They could just as easily write #load settings from d:\data > load "d:\data\settings.gp" That load command is actually wrong. It should be one of load "d:\\data\\settings.gp" load "d:/data/settings.gp" load 'd:\data\settings.gp' load 'd:/data/settings.gp' > Anyway it might be reasonable to change this behavior. No. Changing syntax from what it has been for decades, to match expectations of people who fail to read documentation, is anything but reasonable. |
|
From: Daniel F. <boy...@gm...> - 2008-05-15 15:57:19
|
Hello, Right, thanks for that the range is correct. It is possible to set the time labels to be abbreviated month names? Changing the second set timefmt "%m" doesn't make any difference? Do I need to play with set xtics to do this? Dan On 15 May 2008, at 11:25, Thomas Sefzick wrote: > > you forgot to 'set xdata time' > > your plotfile should read: > > ... > set xdata time > set timefmt "%m.%Y" > set xrange ["12.1999":"01.2001"] > plot 'bars2.txt' using 1:2 title 'A' > > or > > ... > set xdata time > set timefmt "%m.%Y" > set xrange ["12.1999":"01.2001"] > set timefmt "%m" > plot 'bars.txt' using 1:2 title 'A' > > you may adjust the xrange more precisely: > > ... > set timefmt "%d.%m.%Y" > set xrange ["15.12.1999":"18.12.2000"] > set timefmt "%m.%Y" > plot 'bars2.txt' using 1:2 title 'A' > > -- > View this message in context: http://www.nabble.com/Advice-on-boxes-plot-and-setting-xrange-with-a-time-axis-tp17228309p17250154.html > Sent from the Gnuplot - Dev mailing list archive at Nabble.com. > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > gnuplot-beta mailing list > gnu...@li... > https://lists.sourceforge.net/lists/listinfo/gnuplot-beta |
|
From: Thomas S. <t.s...@fz...> - 2008-05-15 10:24:54
|
you forgot to 'set xdata time' your plotfile should read: ... set xdata time set timefmt "%m.%Y" set xrange ["12.1999":"01.2001"] plot 'bars2.txt' using 1:2 title 'A' or ... set xdata time set timefmt "%m.%Y" set xrange ["12.1999":"01.2001"] set timefmt "%m" plot 'bars.txt' using 1:2 title 'A' you may adjust the xrange more precisely: ... set timefmt "%d.%m.%Y" set xrange ["15.12.1999":"18.12.2000"] set timefmt "%m.%Y" plot 'bars2.txt' using 1:2 title 'A' -- View this message in context: http://www.nabble.com/Advice-on-boxes-plot-and-setting-xrange-with-a-time-axis-tp17228309p17250154.html Sent from the Gnuplot - Dev mailing list archive at Nabble.com. |
|
From: Daniel F. <boy...@gm...> - 2008-05-15 09:36:33
|
Hello Thomas, I have made the changes you suggested but it now clips on both sides! It this a bug? Have a look here, http://www.boyfarrell.com/forums/gnuplot/bars2.txt http://www.boyfarrell.com/forums/gnuplot/plot-bars2.txt http://www.boyfarrell.com/forums/gnuplot/plot-bars2.pdf Regards, Dan. On 14 May 2008, at 19:17, Thomas Sefzick wrote: > > set timefmt "%m.%Y" > set xrange ["12.1999":"01.2001"] > set timefmt "%m" > plot 'bars.txt' using 1:2 title 'A' > > explanation: > you can't set the xrange to 'december one year before' with > timefmt "%m" because there is no way to give the year, and > month numbers <= 0 are not allowed. > > note: > gnuplot starts counting time from the 'beginning of epoch', > so if you have only month numbers in your datafile, it automatically > chooses year 2000. > > -- > View this message in context: http://www.nabble.com/Advice-on-boxes-plot-and-setting-xrange-with-a-time-axis-tp17228309p17237732.html > Sent from the Gnuplot - Dev mailing list archive at Nabble.com. > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > gnuplot-beta mailing list > gnu...@li... > https://lists.sourceforge.net/lists/listinfo/gnuplot-beta |
|
From: Shigeharu T. <sh...@ie...> - 2008-05-15 01:56:03
|
shige 05/15 2008 ---------------- I send a patch to modify the graph window's title of the wgnuplot, which is a request on the Japanese BBS "gnuplot QandA". But, I am sorry that the following patch is for gnuplot-4.0.0 since I cannot build the wgnuplot for gnuplot-4.3.0 and gnuplot-4.2.X by VC++ Toolkit 2003 in my computer. ----- From Here ----- diff -uN term/win.trm.ORG term/win.trm --- term/win.trm.ORG Thu May 15 10:24:52 2008 +++ term/win.trm Thu May 15 10:36:29 2008 @@ -118,7 +118,10 @@ /* Interface routines - create list of actions for Windows */ -enum WIN_id { WIN_DEFAULT, WIN_MONOCHROME, WIN_COLOR, WIN_OTHER }; +enum WIN_id { WIN_DEFAULT, WIN_MONOCHROME, WIN_COLOR, + /* shige */ + WIN_GTITLE, + WIN_OTHER }; static struct gen_table WIN_opts[] = { @@ -126,15 +129,25 @@ { "m$onochrome", WIN_MONOCHROME }, { "c$olor", WIN_COLOR }, { "c$olour", WIN_COLOR }, + /* shige */ + { "ti$tle", WIN_GTITLE }, { NULL, WIN_OTHER } }; +/* shige */ +static char WIN_gtitle[MAXTITLELEN] = WINGRAPHTITLE; + static int WIN_last_linetype = -3; /* HBB 20000813: linetype caching */ TERM_PUBLIC void WIN_options() { struct value a; + /* shige */ + TBOOLEAN set_title=FALSE; + + /* shige */ + graphwin.Title = WIN_gtitle; while (!END_OF_COMMAND) { switch(lookup_table(&WIN_opts[0],c_token)) { @@ -142,6 +155,9 @@ graphwin.color = TRUE; strcpy(graphwin.fontname, WINFONT); graphwin.fontsize = WINFONTSIZE; + /* shige */ + graphwin.Title = WINGRAPHTITLE; + set_title = TRUE; c_token++; break; case WIN_MONOCHROME: @@ -152,6 +168,19 @@ graphwin.color = TRUE; c_token++; break; + /* shige */ + case WIN_GTITLE: + c_token++; + if (END_OF_COMMAND) + int_error(c_token, "expecting title text"); + if (isstring(c_token)) + quote_str( WIN_gtitle, c_token, MAXTITLELEN ); + else + copy_str( WIN_gtitle, c_token, MAXTITLELEN ); + c_token++; + set_title = TRUE; + graphwin.Title = WIN_gtitle; + break; case WIN_OTHER: default: if (isstring(c_token)) { @@ -174,6 +203,8 @@ if (IsWindow(graphwin.hWndGraph) && IsIconic(graphwin.hWndGraph)) ShowWindow(graphwin.hWndGraph, SW_SHOWNORMAL); + /* shige */ + if (set_title) GraphChangeTitle(&graphwin); GraphRedraw(&graphwin); } diff -uN src/win/wgnuplib.h.ORG src/win/wgnuplib.h --- src/win/wgnuplib.h.ORG Thu May 15 10:23:46 2008 +++ src/win/wgnuplib.h Thu May 15 10:31:16 2008 @@ -344,6 +344,10 @@ #define WIN30FONT "Courier" #define WINFONT "Arial" +/* shige */ +#define MAXTITLELEN 120 +#define WINGRAPHTITLE "gnuplot graph" + #if 0 enum JUSTIFY { LEFT, CENTRE, RIGHT @@ -354,6 +358,8 @@ void WDPROC GraphClose(LPGW lpgw); void WDPROC GraphStart(LPGW lpgw, double pointsize); void WDPROC GraphEnd(LPGW lpgw); +/* shige */ +void WDPROC GraphChangeTitle(LPGW lpgw); void WDPROC GraphResume(LPGW lpgw); void WDPROC GraphOp(LPGW lpgw, WORD op, WORD x, WORD y, LPCSTR str); void WDPROC GraphPrint(LPGW lpgw); diff -uN src/win/wgraph.c.ORG src/win/wgraph.c --- src/win/wgraph.c.ORG Thu May 15 10:23:46 2008 +++ src/win/wgraph.c Thu May 15 10:32:01 2008 @@ -443,6 +443,13 @@ #endif } +/* shige */ +void WDPROC +GraphChangeTitle(LPGW lpgw) +{ + SetWindowText(lpgw->hWndGraph,lpgw->Title); +} + void WDPROC GraphResume(LPGW lpgw) { diff -uN src/win/winmain.c.ORG src/win/winmain.c --- src/win/winmain.c.ORG Thu May 15 10:23:46 2008 +++ src/win/winmain.c Thu May 15 10:33:12 2008 @@ -241,7 +241,12 @@ graphwin.hInstance = hInstance; graphwin.hPrevInstance = hPrevInstance; + /* shige */ +#if 0 graphwin.Title = "gnuplot graph"; +#else + graphwin.Title = WINGRAPHTITLE; +#endif graphwin.lptw = &textwin; graphwin.IniFile = textwin.IniFile; graphwin.IniSection = textwin.IniSection; ----- To Here ----- +========================================================+ Shigeharu TAKENO NIigata Institute of Technology kashiwazaki,Niigata 945-1195 JAPAN sh...@ie... TEL(&FAX): +81-257-22-8161 +========================================================+ |
|
From: Thomas S. <t.s...@fz...> - 2008-05-14 18:17:41
|
set timefmt "%m.%Y" set xrange ["12.1999":"01.2001"] set timefmt "%m" plot 'bars.txt' using 1:2 title 'A' explanation: you can't set the xrange to 'december one year before' with timefmt "%m" because there is no way to give the year, and month numbers <= 0 are not allowed. note: gnuplot starts counting time from the 'beginning of epoch', so if you have only month numbers in your datafile, it automatically chooses year 2000. -- View this message in context: http://www.nabble.com/Advice-on-boxes-plot-and-setting-xrange-with-a-time-axis-tp17228309p17237732.html Sent from the Gnuplot - Dev mailing list archive at Nabble.com. |
|
From: Daniel F. <boy...@gm...> - 2008-05-14 10:51:09
|
Hello, I have a plot boxes plot which is value of something at every month of the year. I want to change the xrange of the plot, http://www.boyfarrell.com/forums/gnuplot/plot-bars.pdf I want to be able to see all the box in the plot range (January is clipped and December is too large), this means I needs to set the xrange to be slightly larger than the data range i.e. from Jan-1 to Dec +1. However, my xaxis is time in months numbers, 1,2,3 etc... I have tried a few methods of setting the xrange and the xtic placement my can't get it to work. Here is the data and the plotting script, can anybody help? http://www.boyfarrell.com/forums/gnuplot/bars.txt http://www.boyfarrell.com/forums/gnuplot/plot-bars.txt Regards, Dan. |
|
From: Tim H. <hof...@un...> - 2008-05-13 21:21:20
|
Hi, comments can be continuated # this is a comment \ this one too \ even this It's not a real bug, but IMHO people would not expect this. This can lead to strange errors, especially for windows users (I don't know who else would need a \ at the end of a comment): # load settings from d:\data\ load "d:\data\settings.gp" Anyway it might be reasonable to change this behavior. Tim |
|
From: Daniel F. <boy...@gm...> - 2008-05-13 10:56:45
|
Hi, Ethan, that's really cool I'm definitely going to try that! Will have to go in the gnuplot porn gallery when it's done :o) Dan. |