Re: [PUSHED] Re: [PATCH] Bug 50386 - Page count field makes scrolling impossible

2012-06-06 Thread Michael Meeks

On Tue, 2012-06-05 at 20:19 +0200, Michael Stahl wrote:
 thanks a lot for investigating problems caused by your new feature, that
 is much appreciated.

Right ! :-) also, any chance of a screenshot of the updated count in
the status bar we can add to your nice entry (thanks for adding that)
here:

https://wiki.documentfoundation.org/ReleaseNotes/3.6

Thanks !

Michael.

-- 
michael.me...@suse.com  , Pseudo Engineer, itinerant idiot

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [PUSHED] Re: [PATCH] Bug 50386 - Page count field makes scrolling impossible

2012-06-06 Thread Muhammad Haggag

On 06/06/2012 12:49 PM, Michael Meeks wrote:
Right ! :-) also, any chance of a screenshot of the updated count in 
the status bar we can add to your nice entry (thanks for adding that) 
here: https://wiki.documentfoundation.org/ReleaseNotes/3.6 Thanks ! 
Michael. 

Done! :)

Regards,
--Muhammad
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[PUSHED] Re: [PATCH] Bug 50386 - Page count field makes scrolling impossible

2012-06-05 Thread Michael Stahl
On 04/06/12 20:39, Muhammad Haggag wrote:
 Hello.
 
 = Bugs =
 https://bugs.freedesktop.org/show_bug.cgi?id=50386
 https://bugs.freedesktop.org/show_bug.cgi?id=50540
 
 = Patch =
 https://bugs.freedesktop.org/attachment.cgi?id=62532

thanks a lot for investigating problems caused by your new feature, that
is much appreciated.

 = Change =
 This patch fixes a regression caused by my fix for fdo#34772 (adding
 word count to the status bar). The code used to count words was
 wrapped in StartAction/EndAction, which seem to be meant for input
 actions based on keyboard/mouse. EndAction calls UpdateCrsr with the
 SwCrsrShell::SCROLLWIN flag, resulting in the behavior described in
 fdo#50386 and fdo#50540.

yes, the shell Start/EndAction methods likely should only be used for
actual user actions; the intent there is to batch up changes so things
are only re-drawn once or something like that; there is also a different
start/end-action thing used by the UNO API implementation in
source/core/unocore that would leave the view cursor alone.

 We were calling it directly (Start/EndAction) and indirectly (through
 SwWrtShell::GetUpdatedDocStat). I removed the
 direct calls and replaced the SwWrtShell call with
 SwDoc::GetUpdatedDocStat, which doesn't call Start/EndAction.

for simply getting the document statistics no Start/EndAction of any
kind should be necessary because that doesn't change the document content.

hence i've pushed your patch to master and libreoffice-3-6.

 Can someone advise on whether we need the SwWait? It's there because I
 initially copied the code from wordcountdialog.cxx, but I'm not sure
 whether we actually need it (or need it to lock the dispatcher
 either).

i don't know what SwWait does... it seems it disables dispatching, and
calls VCL's Window::EnterWait/LeaveWait, and that causes the mouse
cursor to be changed into a wait-cursor (some kind of clock).

ah, it seems it causes the following odd behavior: new Writer document,
place the mouse cursor over the document area, it is a line cursor.
then type something. notice that few seconds later the word count in the
status bar is updated and simultaneously mouse cursor turns into an
arrow cursor.

so i've just pushed a commit to remove the SwWait line.

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[PATCH] Bug 50386 - Page count field makes scrolling impossible

2012-06-04 Thread Muhammad Haggag
Hello.

= Bugs =
https://bugs.freedesktop.org/show_bug.cgi?id=50386
https://bugs.freedesktop.org/show_bug.cgi?id=50540

= Patch =
https://bugs.freedesktop.org/attachment.cgi?id=62532

= Patch review =
https://bugs.freedesktop.org/page.cgi?id=splinter.htmlbug=50386attachment=62532

= Change =
This patch fixes a regression caused by my fix for fdo#34772 (adding
word count to the status bar). The code used to count words was
wrapped in StartAction/EndAction, which seem to be meant for input
actions based on keyboard/mouse. EndAction calls UpdateCrsr with the
SwCrsrShell::SCROLLWIN flag, resulting in the behavior described in
fdo#50386 and fdo#50540.

We were calling it directly (Start/EndAction) and indirectly (through
SwWrtShell::GetUpdatedDocStat). I removed the
direct calls and replaced the SwWrtShell call with
SwDoc::GetUpdatedDocStat, which doesn't call Start/EndAction.

Can someone advise on whether we need the SwWait? It's there because I
initially copied the code from wordcountdialog.cxx, but I'm not sure
whether we actually need it (or need it to lock the dispatcher
either).

Regards,
--Muhammad
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice