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

List:       kde-kimageshop
Subject:    Re: [calligra/calligra/2.9] krita/plugins/tools/defaulttools: add label to smoothing property so it 
From:       Dmitry Kazakov <dimula73 () gmail ! com>
Date:       2015-02-06 7:18:31
Message-ID: CAEkBSfVQsgjHqgkRe1W-qoZwOV_cG_=KJuFAkMaGCVjgh+_4SA () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


Hi, Scott!

I'm not sure this very change looks ok (probably, it might be fixed somehow
without reverting the patch, I don't know).

Before the change the combo box had a fixed width. That is whatever option
was selected it kept the same look, and therefore looked more highlevel
option that the rest of the list

After your patch the width of the dropdown box is no longer fixed and it
changes its size when the user clicks on it (to select another type of
smoothing). In my opinion such jumping-under-cursor controls look quite
ugly. I feel that we should still show somehow that the type of smoothing
is more highlevel option.



On Thu, Feb 5, 2015 at 6:52 AM, Scott Petrovic <scottpetrovic@gmail.com>
wrote:

> Git commit fb929a857ceb75bfcf96543b935749d4e3ac0877 by Scott Petrovic.
> Committed on 05/02/2015 at 03:52.
> Pushed by scottpetrovic into branch 'calligra/2.9'.
>
> add label to smoothing property so it is more consistent with other options
>
> M  +7    -4    krita/plugins/tools/defaulttools/kis_tool_brush.cc
> M  +2    -0    krita/plugins/tools/defaulttools/kis_tool_brush.h
>
> http://commits.kde.org/calligra/fb929a857ceb75bfcf96543b935749d4e3ac0877
>
> diff --git a/krita/plugins/tools/defaulttools/kis_tool_brush.cc
> b/krita/plugins/tools/defaulttools/kis_tool_brush.cc
> index 40dfd14..8db9ba0 100644
> --- a/krita/plugins/tools/defaulttools/kis_tool_brush.cc
> +++ b/krita/plugins/tools/defaulttools/kis_tool_brush.cc
> @@ -318,14 +318,17 @@ QWidget * KisToolBrush::createOptionWidget()
>      optionsWidget->layout()->addWidget(specialSpacer);
>
>      // Line smoothing configuration
> +    m_smoothingLabel = new QLabel(optionsWidget);
> +    m_smoothingLabel->setText(i18n("Smoothing:"));
> +
>      m_cmbSmoothingType = new QComboBox(optionsWidget);
>      m_cmbSmoothingType->addItems(QStringList()
> -            << i18n("No Smoothing")
> -            << i18n("Basic Smoothing")
> -            << i18n("Weighted Smoothing")
> +            << i18n("None")
> +            << i18n("Basic")
> +            << i18n("Weighted")
>              << i18n("Stabilizer"));
>      connect(m_cmbSmoothingType, SIGNAL(currentIndexChanged(int)), this,
> SLOT(slotSetSmoothingType(int)));
> -    addOptionWidgetOption(m_cmbSmoothingType);
> +    addOptionWidgetOption(m_cmbSmoothingType, m_smoothingLabel);
>
>      m_sliderSmoothnessDistance = new
> KisDoubleSliderSpinBox(optionsWidget);
>      m_sliderSmoothnessDistance->setRange(3.0,
> MAXIMUM_SMOOTHNESS_DISTANCE, 1);
> diff --git a/krita/plugins/tools/defaulttools/kis_tool_brush.h
> b/krita/plugins/tools/defaulttools/kis_tool_brush.h
> index 161b248..08419a1 100644
> --- a/krita/plugins/tools/defaulttools/kis_tool_brush.h
> +++ b/krita/plugins/tools/defaulttools/kis_tool_brush.h
> @@ -34,6 +34,7 @@
>
>  class QCheckBox;
>  class QComboBox;
> +class QLabel;
>  class QGridLayout;
>
>  class KoCanvasBase;
> @@ -115,6 +116,7 @@ private:
>      void addSmoothingAction(int enumId, const QString &id, const QString
> &name, KActionCollection *globalCollection);
>
>  private:
> +    QLabel *m_smoothingLabel;
>      QComboBox *m_cmbSmoothingType;
>
>      QCheckBox *m_chkAssistant;
>
>


-- 
Dmitry Kazakov

[Attachment #5 (text/html)]

<div dir="ltr"><div><div><div><div>Hi, Scott!<br><br></div>I&#39;m not sure this very \
change looks ok (probably, it might be fixed somehow without reverting the patch, I \
don&#39;t know).<br><br></div>Before the change the combo box had a fixed width. That \
is whatever option was selected it kept the same look, and therefore looked more \
highlevel option that the rest of the list<br><br></div>After your patch the width of \
the dropdown box is no longer fixed and it changes its size when the user clicks on \
it (to select another type of smoothing). In my opinion such jumping-under-cursor \
controls look quite ugly. I feel that we should still  show somehow that the type of \
smoothing is more highlevel \
option.<br><br></div><div><div><div><div><br></div></div></div></div></div><div \
class="gmail_extra"><br><div class="gmail_quote">On Thu, Feb 5, 2015 at 6:52 AM, \
Scott Petrovic <span dir="ltr">&lt;<a href="mailto:scottpetrovic@gmail.com" \
target="_blank">scottpetrovic@gmail.com</a>&gt;</span> wrote:<br><blockquote \
class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc \
solid;padding-left:1ex">Git commit fb929a857ceb75bfcf96543b935749d4e3ac0877 by Scott \
Petrovic.<br> Committed on 05/02/2015 at 03:52.<br>
Pushed by scottpetrovic into branch &#39;calligra/2.9&#39;.<br>
<br>
add label to smoothing property so it is more consistent with other options<br>
<br>
M   +7      -4      krita/plugins/tools/defaulttools/kis_tool_brush.cc<br>
M   +2      -0      krita/plugins/tools/defaulttools/kis_tool_brush.h<br>
<br>
<a href="http://commits.kde.org/calligra/fb929a857ceb75bfcf96543b935749d4e3ac0877" \
target="_blank">http://commits.kde.org/calligra/fb929a857ceb75bfcf96543b935749d4e3ac0877</a><br>
 <br>
diff --git a/krita/plugins/tools/defaulttools/kis_tool_brush.cc \
b/krita/plugins/tools/defaulttools/kis_tool_brush.cc<br> index 40dfd14..8db9ba0 \
                100644<br>
--- a/krita/plugins/tools/defaulttools/kis_tool_brush.cc<br>
+++ b/krita/plugins/tools/defaulttools/kis_tool_brush.cc<br>
@@ -318,14 +318,17 @@ QWidget * KisToolBrush::createOptionWidget()<br>
        optionsWidget-&gt;layout()-&gt;addWidget(specialSpacer);<br>
<br>
        // Line smoothing configuration<br>
+      m_smoothingLabel = new QLabel(optionsWidget);<br>
+      m_smoothingLabel-&gt;setText(i18n(&quot;Smoothing:&quot;));<br>
+<br>
        m_cmbSmoothingType = new QComboBox(optionsWidget);<br>
        m_cmbSmoothingType-&gt;addItems(QStringList()<br>
-                  &lt;&lt; i18n(&quot;No Smoothing&quot;)<br>
-                  &lt;&lt; i18n(&quot;Basic Smoothing&quot;)<br>
-                  &lt;&lt; i18n(&quot;Weighted Smoothing&quot;)<br>
+                  &lt;&lt; i18n(&quot;None&quot;)<br>
+                  &lt;&lt; i18n(&quot;Basic&quot;)<br>
+                  &lt;&lt; i18n(&quot;Weighted&quot;)<br>
                    &lt;&lt; i18n(&quot;Stabilizer&quot;));<br>
        connect(m_cmbSmoothingType, SIGNAL(currentIndexChanged(int)), this, \
                SLOT(slotSetSmoothingType(int)));<br>
-      addOptionWidgetOption(m_cmbSmoothingType);<br>
+      addOptionWidgetOption(m_cmbSmoothingType, m_smoothingLabel);<br>
<br>
        m_sliderSmoothnessDistance = new KisDoubleSliderSpinBox(optionsWidget);<br>
        m_sliderSmoothnessDistance-&gt;setRange(3.0, MAXIMUM_SMOOTHNESS_DISTANCE, \
                1);<br>
diff --git a/krita/plugins/tools/defaulttools/kis_tool_brush.h \
b/krita/plugins/tools/defaulttools/kis_tool_brush.h<br> index 161b248..08419a1 \
                100644<br>
--- a/krita/plugins/tools/defaulttools/kis_tool_brush.h<br>
+++ b/krita/plugins/tools/defaulttools/kis_tool_brush.h<br>
@@ -34,6 +34,7 @@<br>
<br>
  class QCheckBox;<br>
  class QComboBox;<br>
+class QLabel;<br>
  class QGridLayout;<br>
<br>
  class KoCanvasBase;<br>
@@ -115,6 +116,7 @@ private:<br>
        void addSmoothingAction(int enumId, const QString &amp;id, const QString \
&amp;name, KActionCollection *globalCollection);<br> <br>
  private:<br>
+      QLabel *m_smoothingLabel;<br>
        QComboBox *m_cmbSmoothingType;<br>
<br>
        QCheckBox *m_chkAssistant;<br>
<br>
</blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature">Dmitry \
Kazakov</div> </div>



_______________________________________________
Krita mailing list
kimageshop@kde.org
https://mail.kde.org/mailman/listinfo/kimageshop


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

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