Review Request 119677: Show the Cursor Pos and FG Color in statusbar
Boudewijn Rempt
boud at valdyas.org
Wed Oct 15 17:56:47 BST 2014
> On Aug. 10, 2014, 8:10 a.m., Dmitry Kazakov wrote:
> > Hi, Latte!
> >
> > Your patch is really cool, but there is one issue that we should fix before we can allow it to go to master.
> >
> > We had the cursor position in the status bar before, but we disabled it due to performance issues. The point is, wacom tablet devices have quite a high resolution, so the application gets too many mouse move events, and, therefore eats too much CPU power if we try to display the coordinate on every event. The same applies to displaying current color. If we try to update the color on every event, the UI will choke when the user starts color picking with a tablet device.
> >
> > Now we have a canned solution for that. You just need to connect the signal not directly to the slot, but using KisSignalCompressor object. This object will ensure that the signal is delivered not more often than, say, once in 100ms. The user will not see any delay, but the system will not choke with the events.
> >
> > You can find an example of how KisSignalCompressor will be used in KisColorSelector class. You will probably want to use higher delay values, e.g. 100ms, because you don't need real-time feedback here.
> >
> > PS:
> > And just to add to what Sven said about coding style, here is a nice document about it:
> > https://techbase.kde.org/Policies/Kdelibs_Coding_Style
Ping? Latte, have you had any chance to update your patch to use the signal compressor? If not, I would say that adding the current color to the statusbar can go in, but the cursor pos is better added to the overview docker.
- Boudewijn
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/119677/#review64141
-----------------------------------------------------------
On Aug. 9, 2014, 11:22 a.m., Latte OfCode wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/119677/
> -----------------------------------------------------------
>
> (Updated Aug. 9, 2014, 11:22 a.m.)
>
>
> Review request for Calligra.
>
>
> Repository: calligra
>
>
> Description
> -------
>
> Two changes to statusbar: 1) Show cursor location, 2) Show foreground color
>
>
> Diffs
> -----
>
> krita/ui/kis_statusbar.h 5b5c74e
> krita/ui/kis_statusbar.cc 7f57007
>
> Diff: https://git.reviewboard.kde.org/r/119677/diff/
>
>
> Testing
> -------
>
> Built Krita successfully after making changes. Tested added functionality.
>
>
> Thanks,
>
> Latte OfCode
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/calligra-devel/attachments/20141015/a18bd307/attachment.htm>
More information about the calligra-devel
mailing list