1. 02 Jan, 2020 1 commit
    • Mathias Wein's avatar
      Fix color selector update issue · d52c63a8
      Mathias Wein authored
      Even though the color may not change when e.g. saturation is zero,
      the other selector shape still needs to update its background
      when hue changes etc.
      d52c63a8
  2. 01 Jan, 2020 1 commit
  3. 31 Dec, 2019 1 commit
    • Mathias Wein's avatar
      Support tablet events in visual color selector · 76d7cb73
      Mathias Wein authored
      By default they are disabled and can be enabled with
      setAcceptTabletEvents(true);
      This should fix input for the popup palette in cases where
      synthesized mouse events are not reliable, hopefully.
      76d7cb73
  4. 29 Dec, 2019 9 commits
    • Mathias Wein's avatar
      Adjust geometry calculation for triangle in circle selector shape · c5ff8aad
      Mathias Wein authored
      Due to the changed margins the triangle can fit a little tighter without
      too much overlap, giving a bit more selector area.
      c5ff8aad
    • Mathias Wein's avatar
      Restructure color selector shapes (again) · 380b3860
      Mathias Wein authored
      Render a separate alpha mask:
      This allows a generic optimization to skip all invisible pixels when
      updating background. For triangle this alpha mask allows to skip ~50%
      pixels that were never displayed.
      Performance for ring shape stayed identical, was hoping for a small
      boost at least...
      
      Rework triangle code:
      Removed some unused variables and use widget space a little better.
      While at it, correct math that assumes certain widget geometry constraints.
      
      TODO: code to fit triangle inside ring needs a tweak.
      TODO: implement alpha mask for rectangle shape.
      380b3860
    • Mathias Wein's avatar
      Make color selector aware of UI scaling · ce7f91a6
      Mathias Wein authored
      Qt virtualizes the coordinate system and keeps it independent
      of (Hi-DPI) UI scaling, that helps to not break applications
      not aware of this feature, but automatically upscaled images
      of course are not very nice especially with fractional factors.
      
      This commit tries to properly determine the true device pixel amounts
      and renders the selector at this resolution.
      
      Note: fractional scaling needs thorough testing with Qt 5.14,
      earlier versions are know to still have many rendering glitches.
      Only tested with Qt 5.12 and QT_SCALE_FACTOR environment variable so far.
      ce7f91a6
    • Mathias Wein's avatar
      Pass QPointF to widget->shape conversion function · bcc079bd
      Mathias Wein authored
      There is no reason to truncate values when QMouseEvent provides
      a QPointF and subsequent calculation are all float too.
      
      NOTE: Qt 5.12 does not appear to calculate QMouseEvent::localPos() with
      with fractional precision yet even though it definitely should with
      fractional UI scaling, and windowPos() does so.
      bcc079bd
    • Mathias Wein's avatar
      Don't round color selector coordinate calculations · 197c0275
      Mathias Wein authored
      QPainter draws float positions just fine, so handles move smoother.
      It was inconsistent between selector shapes anyway.
      Also simplify code a little.
      197c0275
    • Mathias Wein's avatar
      e4eb3834
    • Mathias Wein's avatar
      Ignore mouse events for buttons not handled · dfc96d17
      Mathias Wein authored
      This is required to propagate events for the popup palette
      to close on right-click.
      Also, it is not necessary to track ourselves which buttons are
      pressed, QMouseEvent::buttons() does that already.
      dfc96d17
    • Mathias Wein's avatar
      Fix memory leak in KisSpinboxColorSelector · c305a4c5
      Mathias Wein authored
      c305a4c5
    • Mathias Wein's avatar
      Remove duplicate deleteLater() calls · 9ff499fa
      Mathias Wein authored
      9ff499fa
  5. 21 Dec, 2019 2 commits
  6. 19 Dec, 2019 3 commits
  7. 16 Dec, 2019 1 commit
  8. 09 Dec, 2019 3 commits
  9. 05 Dec, 2019 1 commit
  10. 04 Dec, 2019 8 commits
    • Dmitry Kazakov's avatar
      Fix a crash when cancelling Transform Tool action · 2dc2ed5f
      Dmitry Kazakov authored
      The crash happens only on systems that have asserts enabled, that
      is, don't have NDEBUG defined.
      
      Binding uninitialized '*m_savedTransformArgs' to a cont-reference
      generated valid c++ code (a reference initialized with nullptr),
      and given that finishStrokeImpl() didn't try to use/dereference
      this reference, the code worked fine and didn't crash on systems
      without asserts.
      
      But on systems with asserts enabled (non NDEBUG), boost::optional
      triggered a sanity check assert for dereferencing nullptr and crashed
      the application.
      
      The patch removes entire code for resetting m_savedTransformArgs in
      cancelStrokeCallback(). It was actually an artifact of some initial
      refactoring.
      
      Thanks Fredrik Hansson for pointing out the problem!
      https://invent.kde.org/kde/krita/merge_requests/197
      
      BUG:414672
      2dc2ed5f
    • Boudewijn Rempt's avatar
      Split the log in sysinfo and session log · 2771cd99
      Boudewijn Rempt authored
      2771cd99
    • Boudewijn Rempt's avatar
      Don't leak a QFontComboBox · 465416bd
      Boudewijn Rempt authored
      Because if we do, it won't be deleted before Qt removes all fonts
      on destroying QApplication, and then QFontCombBox will try to get
      an active window.
      
      BUG:414718
      465416bd
    • Boudewijn Rempt's avatar
      Remove KoFontComboBox · 2c57fdf0
      Boudewijn Rempt authored
      2c57fdf0
    • Boudewijn Rempt's avatar
      Remove useless calls to QApplication::globalStrut · 71063ae3
      Boudewijn Rempt authored
      This returns QSize(0,0) in all cases, so it's useless to call it.
      And it's going to be deprecated anyway.
      71063ae3
    • Boudewijn Rempt's avatar
      Give removing the json files a try... · f9e85f48
      Boudewijn Rempt authored
      f9e85f48
    • Boudewijn Rempt's avatar
      011726bf
    • Ivan Yossi's avatar
      Fix 1px brush offset in line tool · b4347512
      Ivan Yossi authored
      This adjust the diferent position of KisPaintInformation
      from a line to be inside a line between starting and
      ending points. This is particularly important as brushes
      that use 1px perfect pixels require the line to be perfect
      in order to avoid looking jagged. In 1px size with
      sharpen active we only use the start and end
      KisPaintInformation points.
      
      This patch also adjusts the outine on 1px brushes to
      adjust to the grid to better preview where the paint is
      going to be applyied
      
      BUG:407405
      b4347512
  11. 03 Dec, 2019 1 commit
    • Agata Cacko's avatar
      Increase the limit in Layer Offset to 100k · f2419f5a
      Agata Cacko authored
      Before this commit, there was no maximum set on the double
      spin box which holded the value. Because by default it would
      be filled with half of the width and height of the layer
      extent, there will be some maximum value set bigger
      than 99 which is the default for double spin boxes.
      This commit fixes this behaviour by setting 100 000
      as a maximum explicitely.
      
      BUG:414625
      f2419f5a
  12. 02 Dec, 2019 3 commits
    • Agata Cacko's avatar
      Fix crash using onion skins on non-animated layers · 089a28f9
      Agata Cacko authored
      Using onion skins on layers without any content keyframes
      is possible if one is using opacity keyframes.
      Before this commit, turning onion skins on would cause a crash.
      After this commit, turning onion skins on will do nothing.
      
      BUG:414668
      089a28f9
    • Agata Cacko's avatar
      Fix Grow Selection expanding in one direction · b49d9789
      Agata Cacko authored
      Before this commit there was a mistake in calculating
      the border of the selection. It was caused by misreading
      the original calculation equation while fixing the
      CID issue (dividing by 0).
      This commit fixes the behaviour by ensuring that
      the value is being multiplied, not divided by sqrt.
      
      BUG:414647
      b49d9789
    • Yuri Chornoivan's avatar
      Update URLs · d4dfd7b6
      Yuri Chornoivan authored
      d4dfd7b6
  13. 01 Dec, 2019 2 commits
  14. 30 Nov, 2019 2 commits
    • Lamarque Souza's avatar
      Fix crash when starting Krita with Qt compiled in debug mode. · 97c03e0f
      Lamarque Souza authored
      This is the backtrace:
      
      0  0x00007ffff38a11cc in KoColorSet::getGroup(QString const&) () from
      /usr/lib64/libkritapigment.so.18
      1  0x00007ffff3d2aa69 in KisPaletteModel::index(int, int, QModelIndex
      const&) const () from /usr/lib64/libkritawidgets.so.18
      2  0x00007ffff5812796 in
      QAbstractItemView::setModel(QAbstractItemModel*) () from
      /usr/lib64/libQt5Widgets.so.5
      3  0x00007ffff582e749 in QHeaderView::setModel(QAbstractItemModel*) ()
      from /usr/lib64/libQt5Widgets.so.5
      4  0x00007ffff5871493 in QTableView::setModel(QAbstractItemModel*) ()
      from /usr/lib64/libQt5Widgets.so.5
      5  0x00007ffff3d31e17 in
      KisPaletteView::setPaletteModel(KisPaletteModel*) () from
      /usr/lib64/libkritawidgets.so.18
      6  0x00007ffff3d2691e in
      KisDlgInternalColorSelector::KisDlgInternalColorSelector(QWidget*,
      KoColor, KisDlgInternalColorSelector::Config, QString const&,
      KoColorDisplayRendererInterface const*) () from
      /usr/lib64/libkritawidgets.so.18
      7  0x00007ffff7000d67 in
      KoDualColorButton::Private::init(KoDualColorButton*) () from
      /usr/lib64/libkritaui.so.18
      8  0x00007ffff7002c5b in KoDualColorButton::KoDualColorButton(KoColor
      const&, KoColor const&, KoColorDisplayRendererInterface const*,
      QWidget*, QWidget*) ()
        from /usr/lib64/libkritaui.so.18
      9  0x00007ffff6e2b5b5 in KisControlFrame::setup(QWidget*) () from
      /usr/lib64/libkritaui.so.18
      10 0x00007ffff71014ea in KisViewManager::KisViewManager(QWidget*,
      KActionCollection*) () from /usr/lib64/libkritaui.so.18
      11 0x00007ffff70cb72b in KisMainWindow::KisMainWindow(QUuid) () from
      /usr/lib64/libkritaui.so.18
      12 0x00007ffff70d8352 in KisPart::createMainWindow(QUuid) () from
      /usr/lib64/libkritaui.so.18
      13 0x00007ffff70d85de in KisPart::startBlankSession() () from
      /usr/lib64/libkritaui.so.18
      14 0x00007ffff70995b9 in KisApplication::start(KisApplicationArguments
      const&) () from /usr/lib64/libkritaui.so.18
      15 0x0000555555e4e229 in main ()
      
      The KisPaletteModel::index() call is inside an Q_ASSERT_X in
      QAbstractItemView::setModel(), so you have to compile Qt in debug mode
      to reproduce this crash.
      
      m_rowGroupNameMap is empty during the startup.
      97c03e0f
    • Kuntal  Majumder's avatar
      Fix segfault while opening text with double click · fcb5c280
      Kuntal Majumder authored
      BUG: 41425
      fcb5c280
  15. 29 Nov, 2019 1 commit
  16. 28 Nov, 2019 1 commit