Hi, Attached below is the patch for the bug #14911.
The patch includes CHANGES.md file and the java file in which changes were done. I was not able to attach the screenshots of the manual non_reg test due to the 100kb constraint. It is still in process of being accepted. Please see the attached screenshots in that mail. If any other changes have to be done or any other files have to be edited, Please tell me. I was also wondering if it's possible for me to directly send pull requests. Thanks
From ec5aa3e54bbaaef918dc5abf15dae131fff8522c Mon Sep 17 00:00:00 2001 From: Nikhil Goel <[email protected]> Date: Fri, 13 Jan 2017 20:06:50 +0530 Subject: [PATCH] add "Label => Title" in the graphic context menu on figures --- scilab/CHANGES.md | 1 + .../gui/src/java/org/scilab/modules/gui/editor/Editor.java | 11 ++++++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/scilab/CHANGES.md b/scilab/CHANGES.md index 494a0a5f..afefe49a 100644 --- a/scilab/CHANGES.md +++ b/scilab/CHANGES.md @@ -436,6 +436,7 @@ Bug Fixes * [#14839](http://bugzilla.scilab.org/show_bug.cgi?id=14839): `plot2d2` crashed Scilab. * [#14887](http://bugzilla.scilab.org/show_bug.cgi?id=14887): For many graphic handle types, the display of the `.tag` value missed `".."` delimiters * [#14909](http://bugzilla.scilab.org/show_bug.cgi?id=14909): getlongpathname and getshortpathname return values with "\" instead of "/" +* [#14911]{http://bugzilla.scilab.org/show_bug.cgi?id=14911): add "Label => Title" in the graphic context menu on figures * [#14941](http://bugzilla.scilab.org/show_bug.cgi?id=14941): `find` did not accept encoded integers * [#14942](http://bugzilla.scilab.org/show_bug.cgi?id=14942): Keep the Tkscale block label if block already has label. diff --git a/scilab/modules/gui/src/java/org/scilab/modules/gui/editor/Editor.java b/scilab/modules/gui/src/java/org/scilab/modules/gui/editor/Editor.java index b448d420..ad6a8657 100644 --- a/scilab/modules/gui/src/java/org/scilab/modules/gui/editor/Editor.java +++ b/scilab/modules/gui/src/java/org/scilab/modules/gui/editor/Editor.java @@ -65,7 +65,7 @@ import org.scilab.modules.action_binding.highlevel.ScilabInterpreterManagement; public class Editor { JPopupMenu menu; - JMenuItem copy, copyStyle, cut, paste, pasteStyle, delete, clear, hide, unhide, clipboardCopy, labelX, labelY, labelZ, insert, remove, ged, editdata, undo, redo; + JMenuItem copy, copyStyle, cut, paste, pasteStyle, delete, clear, hide, unhide, clipboardCopy, labelX, labelY, labelZ, title, insert, remove, ged, editdata, undo, redo; JMenu labels, legends; EntityPicker.LegendInfo selectedLegend = null; @@ -318,6 +318,8 @@ public class Editor { labelY.setToolTipText(Messages.gettext("Insert a label in Y axis")); labelZ = new JMenuItem(Messages.gettext("Label Z")); labelZ.setToolTipText(Messages.gettext("Insert a label in Z axis")); + title = new JMenuItem(Messages.gettext("Title")); + title.setToolTipText(Messages.gettext("Insert a label in title")); insert = new JMenuItem(Messages.gettext("Insert")); insert.setToolTipText(Messages.gettext("Insert a legend into the selected curve")); remove = new JMenuItem(Messages.gettext("Remove")); @@ -400,6 +402,12 @@ public class Editor { onClickLabel(AxesHandler.axisTo.__Z__); } }); + + title.addActionListener(new ActionListener() { + public void actionPerformed(ActionEvent actionEvent) { + onClickLabel(AxesHandler.axisTo.__TITLE__); + } + }); insert.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent actionEvent) { @@ -453,6 +461,7 @@ public class Editor { labels.add(labelX); labels.add(labelY); labels.add(labelZ); + labels.add(title); legends.add(insert); legends.add(remove); menu.add(copy); -- 2.11.0
_______________________________________________ dev mailing list [email protected] http://lists.scilab.org/mailman/listinfo/dev
