Closed dtg3 closed 5 years ago
yes we can disable code folding in Eclipse
Okay. This issue will be left open as a reminder for environment configuration/demo setup. After the demo, we can evaluate the feasibility of updating the plugin to accommodate code folding.
I think by default eclipse has word wrap off, but that might also be another setting that could throw off our values.
Fixed with the recent pull request #15
TLDR; Code folding seems to be throwing off line col values. We should disable it in the editor for demo and fix it properly later (if that's possible)
Line numbers tend to be a bit off. I've done quite a bit of testing for this, and I think this might be due to code folding.
On a small file (AbstractColorSlidersModel.java JHotDraw7 - jhotdraw7.zip) I ran my mouse over line 34 left to right up to col 54 and then back. The values for line were off by about 5 or so lines, and the col was only off a little (which I think is fine because the plugin returns a zero starting col vs the 1 based number from the editor).
I'm going by the line and col attributes only because I assume that everything else between the
<sces>
tag will also not be used/needed.What makes me think this is a folding issue is that the numbers seem to be accurate at the top of the file, but the further down you go (past folded code) the values start to go off.
Steps to repeat: 1) Open Eclipse plugin (Have editor full screen) 2) Connect to Core 3) Start tracking 4) Carefully move mouse over an individual line (Click to see line column in bottom of eclipse editor) 5) Stop plugin/core 6) View output file
Someone else should validate this, but my suggestion is to turn off folding from the menu:
window->preferences
thenGeneral->Editors->Structured Text Editors
and uncheckenable folding
. You also need to remove it for Java using:window->preferences
then 'Java->Editor->Foldingand uncheck
enable folding`After removing code folding the mouse results seemed much more accurate.