bugGNU Octave - Bugs: bug #45301, Ghostscript error if title...

 
 

bug #45301: Ghostscript error if title contains ')'

Submitter:  None
Submitted:  Thu 11 Jun 2015 08:20:30 AM UTC
   
 
Category:  Plotting with OpenGL Severity:  3 - Normal
Priority:  3 - Low Item Group:  Incorrect Result
Status:  Fixed Assigned to:  None
Originator Name:  Originator Email:  -email is unavailable-
Open/Closed:  * Closed Release:  * 4.0.0
Operating System:  * GNU/Linux Fixed Release:  None
Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Wed 14 Oct 2015 09:46:31 PM UTC, comment #5: 

I pushed a patch that unconditionally escapes parenthesis before printing:

http://hg.savannah.gnu.org/hgweb/octave/rev/4e47e10d5279

Closing report.

Pantxo Diribarne <pantxo>
Group Member
Sat 13 Jun 2015 06:22:21 AM UTC, comment #4: 

"Test a.)" is a common title, but it's okay to lower this because there is a workaround.

Anonymous
Sat 13 Jun 2015 12:12:40 AM UTC, comment #3: 

I'm lowering the priority the priority since 1) there is a workaround, and 2) unpaired parentheses are fairly rare in text.

Rik <rik5>
Group administrator
Fri 12 Jun 2015 11:44:52 AM UTC, comment #2: 

The request to escape special characters in gl2ps has been formally accepted by the gl2ps maintainer: http://www.geuz.org/pipermail/gl2ps/2015/000413.html

It looks like a long/fastidious task and I don't know when someone will find the time to write the patch gl2ps. Anyway, as noted by the OP, there is a workaround in Octave: escape special characters.

Pantxo Diribarne <pantxo>
Group Member
Thu 11 Jun 2015 11:21:26 AM UTC, comment #1: 

Hi,

I can confirm this bug: any text with an unmatched parenthesis will trigger the bug.
I suppose gl2ps is a better place to fix this as it is responsible for producing valid files whatever the text we want to print: the base eps file, that we use for producing other formats, is invalid because of this unmatched parenthesis.

Pantxo Diribarne <pantxo>
Group Member
Thu 11 Jun 2015 08:20:30 AM UTC, original submission:  


plot (1:2); title ("a)"); print ("out.pdf")


gives


Error: /syntaxerror in -file-
Operand stack:
   --nostringval--   (a)
Execution stack:
   %interp_exit   .runexec2   --nostringval--   --nostringval--   --nostringval--   2   %stopped_push   --nostringval--   --nostringval--   --nostringval--   false   1   %stopped_push   1910   1   3   %oparray_pop   1909   1   3   %oparray_pop   --nostringval--   1893   1   3   %oparray_pop   1787   1   3   %oparray_pop   --nostringval--   %errorexec_pop   .runexec2   --nostringval--   --nostringval--   --nostringval--   2   %stopped_push
Dictionary stack:
   --dict:1171/1684(ro)(G)--   --dict:0/20(G)--   --dict:82/200(L)--   --dict:40/64(L)--
Current allocation mode is local
GPL Ghostscript 9.06: Unrecoverable error, exit code 1


graphics_toolkit gnuplot works fine.

It's possible to escape it:

title ('a\)');


But I think Octave should handle this internal.

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Digest:
   bug dependencies.

 

Carbon-Copy List
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by pantxo (Posted a comment)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2016-05-13 mtmiller Dependencies- bugs #47907 is dependent
    2015-10-14 pantxo StatusConfirmed Fixed
        Open/ClosedOpen Closed
    2015-06-13 rik5 Priority5 - Normal 3 - Low
    2015-06-11 pantxo Item GroupNone Incorrect Result
        StatusNone Confirmed

    Back to the top

    Powered by Savane 3.13-f8d8.
    Corresponding source code