bugGNU Octave - Bugs: bug #56114, GUI should gray out Editor options...

 
 

bug #56114: GUI should gray out Editor options in Window Menu when Qscintilla is not present

Submitted by:  Rik <rik5>
Submitted on:  Wed 10 Apr 2019 04:52:09 PM UTC  
 
Category:  GUI Severity:  1 - Wish
Priority:  5 - Normal Item Group:  Feature Request
Status:  Fixed Assigned to:  None
Originator Name:  Open/Closed:  Closed
Release:  dev Operating System:  Any

Add a New Comment (Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Thu 18 Jul 2019 05:34:01 AM UTC, comment #3: 

Changeset http://hg.savannah.gnu.org/hgweb/octave/rev/922c47ff5218 fices this issue. There already was a test for a valid widget pointer during creation of the entries in the window menu in order to not connect a signal to a non-existing widget. However the menu entry itself was not disabled up to now.

Torsten Lilge <ttl>
Project Member
Mon 27 May 2019 07:00:19 PM UTC, comment #2: 

We could make it conditional on whether the window was constructed.  The code will then look very much like C where you have to check the validity of the pointer every time before you use it.

I don't imagine that we are going to support very many foreign embedded editors.  Wouldn't the code look cleaner if we just used the singular #ifdef.  It would be in one place so that if we ever add additional editors it would be a trivial change to add it to the #ifdef.

Rik <rik5>
Project Administrator
Thu 11 Apr 2019 08:31:59 AM UTC, comment #1: 

I agree that the settings should be disabled if there is no editor available.  For now that requires qscintilla, but it may not in the future so I'd prefer to use something other than HAVE_QSCINTILLA.  Can we make it conditional on whether the editor window is constructed?

John W. Eaton <jwe>
Project Administrator
Wed 10 Apr 2019 04:52:09 PM UTC, original submission:  

When the build is configured using '--without-qscintilla' the Editor is not available in the GUI.  This is fine, but Window menu still displays a checkbox for showing the Editor, as well as an option for switching to the Editor window.  Both of those choices should be disabled when the Editor is not available.

I don't know exactly where to insert the code, but I imagine that after the construction of the menu we need something like this (pseudocode)

#if ! defined (HAVE_QSCINTILLA)
  mark_qt_menu ("Window/Editor", disabled);
#endif

Rik <rik5>
Project Administrator

 

(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

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by ttl (Posted a comment)
  • -email is unavailable- added by jwe (Posted a comment)
  • -email is unavailable- added by rik5 (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

     

     

    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2019-07-18 ttl StatusConfirmed => Fixed
        Open/ClosedOpen => Closed

    Back to the top


    Powered by Savane 3.5