Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-47443

QSizeGrip: add optional mirrored resizing

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Unresolved
    • P5: Not important
    • None
    • 5.5.1
    • None
    • Lubuntu 15.04 on MacBook 2,1

    Description

      I recently implemented a platform independent dialog inspired by the NSSheet dialog in OSX. The result came out fairly acceptable, but ... I was a little surprised how difficult that is with Qt (version <=5.5). I actually copied / reimplemented most of QSizeGrip's pimpl stuff to get it close to the resizing behaviour of NSSheet.

      Although this might not be a "killer feature", some extensions to QSizeGrip would greatly help with such task.

      What about adding some hints, that influence the resizing algorithm in QSizeGrip::mouseMoveEvent? Something similar to this enum:

      class QSizeGrip {
      public:
        enum ResizeHint {
          ResizeDefault = 0,
          ResizeMirrorHorizontal = 1,
          ResizeMirrorVertical = 2
        };
        // add QFlags definition for combination
      };
      

      Now when calculating the new size - which is done in mouseMoveEvent - the delta width/height can be mirrored to the oposite edge of the associated parent widget - still respecting the d->dxMax and d->dyMax values.

      If you give me some introduction how to provide a request for Gerrit, I'll happily implement this and provide my first contribution to Qt.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            antis81 Nils Fenner
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes