Rainie3535 / sigil

Automatically exported from code.google.com/p/sigil
GNU General Public License v3.0
0 stars 0 forks source link

Book View line/column incorrect in status bar #1215

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
0.5.0 Ubuntu 11.10

When entering Book View the cursor line/column values in the status bar are 
wrong.  They are either 0,0 (which is understandable) or they are they last 
value from Code View (which is confusing). CV is ok, and text tabs (ncx, etc.) 
are ok.

In BV the status bar should be blank, always 0,0, or the correct line/column.

In FlowTab::EnterEditor as you set m_IsLastViewBook = true, you can add a call 
to EmitUpdateCursorPosition();  (possibly also in EnterBookView).  This fixes 
the status bar to always be 0,0 in BV.

To make it blank, try emit UpdateCursorPosition( -1, -1 ) instead and in 
MainWindow::UpdateCursorPositionLabel if line or column is < 0 set the text to 
blank.

Ideally it should be the real line/column in BV. Its not clear how to get the 
line/column in BV as its a webpage (although editable at the moment) - probably 
some javascript?   Since there's no connect signal for cursorPositionChanged or 
GetCursorLine/Column for BV it was clearly left out on purpose.

Original issue reported on code.google.com by meme90...@gmail.com on 30 Jan 2012 at 7:31

GoogleCodeExporter commented 9 years ago
Revision: fb083a470f17.

Went with using -1, -1 for N/A and not showing in this case.

Original comment by john@nachtimwald.com on 31 Jan 2012 at 2:01

GoogleCodeExporter commented 9 years ago

Original comment by john@nachtimwald.com on 31 Jan 2012 at 2:02

GoogleCodeExporter commented 9 years ago

Original comment by john@nachtimwald.com on 31 Jan 2012 at 2:02

GoogleCodeExporter commented 9 years ago

Original comment by daveheil...@gmail.com on 19 May 2012 at 3:20