Bug 153375 - [PATCH] Select All does not select all
Summary: [PATCH] Select All does not select all
Alias: None
Product: kate
Classification: Unclassified
Component: kwrite (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR normal (vote)
Target Milestone: ---
Assignee: KWrite Developers
Depends on:
Reported: 2007-12-03 22:06 UTC by Edwin Schepers
Modified: 2007-12-06 05:50 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:

patch for review (832 bytes, patch)
2007-12-05 16:20 UTC, Thomas Friedrichsmeier

Note You need to log in before you can comment on or make changes to this bug.
Description Edwin Schepers 2007-12-03 22:06:40 UTC
Version:           latest svn (using KDE Devel)
Installed from:    Compiled sources
Compiler:          gcc
OS:                Linux (x86_64) release 2.6.22-5-default

When I ctrl-A on this document ( view source in konqueror on http://doc.trolltech.com/4.3-snapshot/qfiledialog.html )
and then ctrl-A, only some text is selected.
When I put focus on another window or resize, only then all text gets selected.

Comment 1 Thomas Friedrichsmeier 2007-12-05 16:20:25 UTC
Created attachment 22357 [details]
patch for review

The attached patch appears to fix the problem, but please review, and tell me
whether it's ok to commit.

Problem seems to be that KateViewInternal::tagLines() (called from
KateView::setSelection()) never updates the view cache. While at it, I removed
a bit of redundant logic in KateViewInternal::updateSelection(). This calls
KateView::clearSelection(), which is (now) enough to update the view.
Comment 2 Hamish Rodda 2007-12-06 05:50:08 UTC
SVN commit 745398 by rodda:

Commit slightly modified version of patch provided by Thomas Friedrichsmeier to fix bug 153375 (select all not correctly rendered)

The only modification was to place the update call after the sanity checks, if the tagging was not for lines on the view, we don't need to update at this point.

BTW, much of this will have to be re-done post 4.0 in order to fix an entirely separate issue (memory usage terrible for large files without newlines)


 M  +2 -6      kateviewinternal.cpp  

WebSVN link: http://websvn.kde.org/?view=rev&revision=745398