[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: Review Request: Make mouse cursor size configurable
From:       Fredrik_Höglund <fredrik () kde ! org>
Date:       2011-11-09 18:20:30
Message-ID: 20111109182030.9176.98751 () vidsolbach ! de
[Download RAW message or body]

> On Nov. 9, 2011, 6:48 a.m., Fredrik Höglund wrote:
> > kcontrol/input/xcursor/cursortheme.cpp, line 119
> > <http://git.reviewboard.kde.org/r/101701/diff/2/?file=33417#file33417line119>
> > 
> > Scaling a pixmap is more expensive than scaling an image. Internally it involves \
> > converting the pixmap back to an image, scaling it, and then converting the image \
> > back to a pixmap. 
> > This is not a major issue, but it's the reason the image was scaled before it was \
> > converted to a pixmap. 
> 
> Lukas Sommer wrote:
> The problem is that I can't drop createIcon(int size) because I need it on other \
> places. So I would either have to copy the code to createIcon() or change the \
> return type of createIcon to QImage. Maybe we can leave this for a later revision?

Like I said, it's not an issue that needs to be fixed now.


- Fredrik


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/101701/#review8036
-----------------------------------------------------------


On Sept. 2, 2011, 4:40 p.m., Lukas Sommer wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/101701/
> -----------------------------------------------------------
> 
> (Updated Sept. 2, 2011, 4:40 p.m.)
> 
> 
> Review request for KDE Base Apps, KDE Runtime, kdelibs, and Christoph Feck.
> 
> 
> Description
> -------
> 
> X11 mouse cursor themes can contain cursors in multiple sizes, making them \
> pseudo-scalable. 
> It is yet possible in KDE to configure manually the mouse cursor size (editing \
> kcminput.rc). However, the GUI of the corresponding KControl module didn't provide \
> support to change this. This patch add support for changing the mouse cursor size \
> to the GUI. 
> This are mostly GUI related changes. The underlying data structure XCursorTheme did \
> yet provide support for choosing different sizes and only needed some adjustments. 
> 
> This addresses bug 90444.
> http://bugs.kde.org/show_bug.cgi?id=90444
> 
> 
> Diffs
> -----
> 
> kcontrol/input/xcursor/cursortheme.h 586ccba 
> kcontrol/input/xcursor/cursortheme.cpp 92abea5 
> kcontrol/input/xcursor/legacytheme.h 846bf9b 
> kcontrol/input/xcursor/previewwidget.h f4d2c4e 
> kcontrol/input/xcursor/previewwidget.cpp 3c264fc 
> kcontrol/input/xcursor/themepage.h 38ca893 
> kcontrol/input/xcursor/themepage.cpp 6c9f29a 
> kcontrol/input/xcursor/themepage.ui 2e38054 
> kcontrol/input/xcursor/xcursortheme.h b474086 
> kcontrol/input/xcursor/xcursortheme.cpp 2ecb9ba 
> 
> Diff: http://git.reviewboard.kde.org/r/101701/diff/diff
> 
> 
> Testing
> -------
> 
> Tested locally. Works fine for me. Also when using non-standard font DPI values.
> 
> 
> Screenshots
> -----------
> 
> 
> http://git.reviewboard.kde.org/r/101701/s/248/
> 
> 
> Thanks,
> 
> Lukas Sommer
> 
> 


[Attachment #3 (text/html)]

<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 \
solid;">  <tr>
     <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="http://git.reviewboard.kde.org/r/101701/">http://git.reviewboard.kde.org/r/101701/</a>
  </td>
    </tr>
   </table>
   <br />








<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <p style="margin-top: 0;">On November 9th, 2011, 6:48 a.m., <b>Fredrik \
Höglund</b> wrote:</p>  <blockquote style="margin-left: 1em; border-left: 2px solid \
#d0d0d0; padding-left: 10px;">  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; \
border-collapse: collapse; margin: 2px padding: 2px;">  <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; \
font-size: 9pt; padding: 4px 8px; text-align: left;">  <a \
href="http://git.reviewboard.kde.org/r/101701/diff/2/?file=33417#file33417line119" \
style="color: black; font-weight: bold; text-decoration: \
underline;">kcontrol/input/xcursor/cursortheme.cpp</a>  <span style="font-weight: \
normal;">

     (Diff revision 2)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="4"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">static \
int nominalCursorSize(int iconSize)</pre></td>

  </tr>
 </tbody>




 
 



 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2"></font></th>  <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>  <th \
bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid \
#C0C0C0;" align="right"><font size="2">119</font></th>  <td bgcolor="#c5ffc4" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">            \
<span class="n">pixmap</span> <span class="o">=</span> <span \
class="n">pixmap</span><span class="p">.</span><span class="n">scaled</span><span \
class="p">(</span><span class="n">size</span><span class="p">,</span> <span \
class="n">Qt</span><span class="o">::</span><span \
class="n">KeepAspectRatio</span><span class="p">,</span> <span \
class="n">Qt</span><span class="o">::</span><span \
class="n">SmoothTransformation</span><span class="p">);</span></pre></td>  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Scaling a pixmap is more \
expensive than scaling an image. Internally it involves converting the pixmap back to \
an image, scaling it, and then converting the image back to a pixmap.

This is not a major issue, but it&#39;s the reason the image was scaled before it was \
converted to a pixmap. </pre>
 </blockquote>



 <p>On November 9th, 2011, 11:45 a.m., <b>Lukas Sommer</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">The problem is that I \
can&#39;t drop createIcon(int size) because I need it on other places. So I would \
either have to copy the code to createIcon() or change the return type of createIcon \
to QImage. Maybe we can leave this for a later revision?</pre>  </blockquote>







</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; \
white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Like I \
said, it&#39;s not an issue that needs to be fixed now.</pre> <br />




<p>- Fredrik</p>


<br />
<p>On September 2nd, 2011, 4:40 p.m., Lukas Sommer wrote:</p>






<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" \
style="background-image: \
url('http://git.reviewboard.kde.org/media/rb/images/review_request_box_top_bg.png'); \
background-position: left top; background-repeat: repeat-x; border: 1px black \
solid;">  <tr>
  <td>

<div>Review request for KDE Base Apps, KDE Runtime, kdelibs, and Christoph \
Feck.</div> <div>By Lukas Sommer.</div>


<p style="color: grey;"><i>Updated Sept. 2, 2011, 4:40 p.m.</i></p>






<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
 <table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" \
style="border: 1px solid #b8b5a0">  <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">X11 mouse cursor themes can contain cursors in multiple sizes, making \
them pseudo-scalable.

It is yet possible in KDE to configure manually the mouse cursor size (editing \
kcminput.rc). However, the GUI of the corresponding KControl module didn&#39;t \
provide support to change this. This patch add support for changing the mouse cursor \
size to the GUI.

This are mostly GUI related changes. The underlying data structure XCursorTheme did \
yet provide support for choosing different sizes and only needed some \
adjustments.</pre>  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: \
1px solid #b8b5a0">  <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">Tested locally. Works fine for me. Also when using non-standard font DPI \
values.</pre>  </td>
 </tr>
</table>



<div style="margin-top: 1.5em;">
 <b style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Bugs: </b>


 <a href="http://bugs.kde.org/show_bug.cgi?id=90444">90444</a>


</div>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>kcontrol/input/xcursor/cursortheme.h <span style="color: \
grey">(586ccba)</span></li>

 <li>kcontrol/input/xcursor/cursortheme.cpp <span style="color: \
grey">(92abea5)</span></li>

 <li>kcontrol/input/xcursor/legacytheme.h <span style="color: \
grey">(846bf9b)</span></li>

 <li>kcontrol/input/xcursor/previewwidget.h <span style="color: \
grey">(f4d2c4e)</span></li>

 <li>kcontrol/input/xcursor/previewwidget.cpp <span style="color: \
grey">(3c264fc)</span></li>

 <li>kcontrol/input/xcursor/themepage.h <span style="color: \
grey">(38ca893)</span></li>

 <li>kcontrol/input/xcursor/themepage.cpp <span style="color: \
grey">(6c9f29a)</span></li>

 <li>kcontrol/input/xcursor/themepage.ui <span style="color: \
grey">(2e38054)</span></li>

 <li>kcontrol/input/xcursor/xcursortheme.h <span style="color: \
grey">(b474086)</span></li>

 <li>kcontrol/input/xcursor/xcursortheme.cpp <span style="color: \
grey">(2ecb9ba)</span></li>

</ul>

<p><a href="http://git.reviewboard.kde.org/r/101701/diff/" style="margin-left: \
3em;">View Diff</a></p>



<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Screenshots </h1>

<div>

 <a href="http://git.reviewboard.kde.org/r/101701/s/248/"><img \
src="http://git.reviewboard.kde.org/media/uploaded/images/2011/09/02/snapshot3_400x100.png" \
style="border: 1px black solid;" alt="" /></a>

</div>


  </td>
 </tr>
</table>








  </div>
 </body>
</html>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic