Closed GoogleCodeExporter closed 9 years ago
Are they both in the same JFrame? I tried this, and it works with the latest
svn
copy. I did not check the binary release as it did have some issues I fixed
already.
Original comment by ayman.al...@gmail.com
on 10 Mar 2009 at 11:19
Both jsyntaxpanes are within the same JFrame, but live within different
JPanels. I
tried using the latest r095 branch with the same results. Perhaps it is how I
initialize them? I run the following code every time I create a new
jsyntaxpane.
DefaultSyntaxKit.initKit();
/* Init and Add Code Panel */
JEditorPane editorPane = new JEditorPane();
JScrollPane scrollPane = new JScrollPane(editorPane);
editorPane.setContentType("text/java");
Original comment by chad.dor...@gmail.com
on 10 Mar 2009 at 10:41
After some debug with your source code I have found the issue. Each time you
call
addActions() in DefaultSyntaxKit class you find the default actions and
configure
them to better appear in the GUI. This is a great, except you rename the
Actions
when modifying them to appear friendlier(for example: "cut-to-clipboard" becomes
"Cut"). Once this is done the first time, the default Actions can not be found
by
their default names the second time around, and therefore do not get included
in your
right click menu, or in the ActionMap at all for that matter.
Original comment by chad.dor...@gmail.com
on 11 Mar 2009 at 5:37
Many thanks! I was pulling my hair trying to recreate, but i could not.
Now I see the problem. But it will be tricky solving it.
Original comment by ayman.al...@gmail.com
on 11 Mar 2009 at 5:53
Fixed in r99 in svn.
Wasn't too tricky after all!
Original comment by ayman.al...@gmail.com
on 11 Mar 2009 at 6:23
That did the trick. Thanks!
Original comment by chad.dor...@gmail.com
on 11 Mar 2009 at 6:33
Original issue reported on code.google.com by
chad.dor...@gmail.com
on 10 Mar 2009 at 7:31