QT Widgets

QT Widgets Framework

A Collection of Reusable QT Widgets to simplify app development.
By: Shotgun Software
Latest Version: v2.5.18 (prod)
For our version numbers, we follow the Semantic Versioning standard.
System Name: tk-framework-qtwidgets

Overview

A collection of Toolkit Related QT widgets. Includes a help popup screen, a standard delegate view framework and a standard spinner overlay.

Documentation

The API Reference documentation for this Framework can be found here:

http://developer.shotgunsoftware.com/tk-framework-qtwidgets

Installation and Updates

Updating to the latest version

If you already have this item installed in a project and you want to get the latest version, you can run the update command. You can either navigate to the tank command that comes with that specific project, and run it there:

> cd /my_tank_configs/project_xyz
> ./tank updates

Alternatively, you can run your studio tank command and specify the project name to tell it which project to run the update check for:

> tank Project XYZ updates

Collaboration and Evolution

If you have access to the Shotgun Pipeline Toolkit, you also have access to the source code for all apps, engines and frameworks in Github where we store and manage them. Feel free to evolve these items; use them as a base for further independent development, make changes (and submit pull requests back to us!) or simply tinker with them to see how they have been built and how the toolkit works. You can access this code repository at https://github.com/shotgunsoftware/tk-framework-qtwidgets.

Special Requirements

  • You need Shotgun Pipeline Toolkit Core API version v0.14.58 or higher to use this.

Configuration

No Configuration Needed!

This item does not have any options to configure!

Release Notes

Welcome to the release notes for this Framework. Below you will find an overview of all the changes we did for each release. We try to be as detailed as possible and include all bugs we have fixed, features we have added and things that may have changed. If you have questions about a particular release, don't hesitate to contact our support team!

v2.5.18

2017-Mar-15

Removes problematic profiles from png files used as icons.

Details:

This will silence libpng warnings from Qt when the png files are loaded as pixmaps. This is a second attempt as this profile stripping, and uses ImageMagick's "mogrify" command to achieve the desired result, which maintains color consistency.

v2.5.16

2017-Feb-17

Properly addresses new Note entities to include the creator of the linked-to entity.

v2.5.15

2017-Jan-06

Adds a field widget delegate that does not require a ShotgunModel

v2.5.14

2017-Jan-06

Adds a field widget delegate that does not require a ShotgunModel

v2.5.13

2016-Dec-19

Fixes a bug in activity stream data manager destroy

v2.5.12

2016-Nov-22

Fixes default key navigation in SG menu

v2.5.11

2016-Nov-19

Field menu polish

v2.5.10

2016-Oct-07

Adds get_hyperlink_html utility function that defines standard hyperlink styling.

v2.5.9

2016-Sep-28

Activity stream widget no longer shows multiple notes in the UI after a reply.

v2.5.8

2016-Sep-27

SG menu now scrollable when size extends beyond height of display

v2.5.7

2016-Sep-22

Hotfix for qtwidgets docs build

v2.5.6

2016-Sep-16

Styling tweaks for ActivityStreamWidget. These account for the needs to of both Shotgun Panel and Shotgun Review for RV.

v2.5.5

2016-Sep-13

Styling fixes and general debugging of editable fields in the VersionDetailsWidget.

Details:

As editable shotgun fields widgets are being used in RV for the first time, some styling tweaks were required. In addition, some bugs and performance issues were discovered during RV's QA process that necessitated a number of fixes and tweaks to various components within the framework.

v2.5.4

2016-Sep-12

Adds backward compatibility support for project searching via entity and multi entity field widgets

v2.5.3

2016-Sep-02

Polish for field widgets in version details

v2.5.2

2016-Sep-01

Polish for field widgets and associated classes based on QA

v2.5.1

2016-Aug-25

Fixes for entity edit widgets as per QA notes

v2.5.0

2016-Aug-23

Shotgun fields in the VersionDetailsWidget are now editable.

Details:

Once edited in the widget, those changes are sent to Shotgun and the fields are updated there. Along with this feature comes additional getters on shotgun_fields widgets.

v2.4.3

2016-Aug-12

Removes the use of collections.OrderedDict in the VersionDetails widget.

Details:

The OrderedDict class is not available in Python versions older than 2.7.

v2.4.2

2016-Aug-10

Fixed bugs around note creation when running in a site context

v2.4.1

2016-Aug-08

Adds attachments filtering mechanism and new note autoselection to the activity stream widget.

v2.4.0

2016-Aug-03

Adds a VersionDetailsWidget Qt widget and its associated classes.

Details:

A version details widget has been added. This widget makes use of Shotgun's activity stream data to present a user with a view into a Version entity's activity stream, plus a second tab displaying a list of related Version entities found in Shotgun. In addition, a ShotgunSortFilterProxyModel class is provided for sorting and filtering Shotgun data in a list view.

v2.3.7

2016-Jul-19

Allow the editor widgets to be used with the shotgunmodel

v2.3.6

2016-Jul-01

Uses SG_LINK_COLOR qss constant when it is available, and bubbles up the ability to turn off clickable user icons from lower-level activity stream widgets.

v2.3.5

2016-Jun-22

Allows field specific widget registration via class member

v2.3.4

2016-Jun-21

Adds ability to register widgets for specific entity/type

v2.3.3

2016-Jun-14

[minor] Adds a property for image_url in shotgun_fields.image_widget.

v2.3.2

2016-Jun-13

Bug fix related to decorator application order for shotgun_fields' metaclass.

v2.3.1

2016-Jun-07

Allows for a pre-submission callback to be registered for use during Note/Reply entity creation.

Details:

The new callback has been put into place to allow higher-level app code to do something like procedurally generate attachments for a new Note/Reply at the time of submission. In addition, the use of QtCore.Property in the version stream widget has been replaced with normal Python property() calls to ensure compatibility with more than just PySide (ie: PyQt4).

v2.3.0

2016-May-25

Adds editing functionality to shotgun fields widgets

v2.2.1

2015-Dec-09

HierarchicalFilteringProxyModel now listens to reset signals from its source model.

Details:

When the HierarchicalFilteringProxyModel model receives the reset signal it will automatically clear its cache of model indices. This will allow the source model to delete its nodes much quicker since there will not be any QPersistentModelIndex caches to update.

v2.2.0

2015-Nov-23

Updated to use v4.x.x of the Shotgun Utils framework.

v2.1.0

2015-Nov-10

Added new widgets extracted from the Shotgun Panel app.

Details:

  • Added sphinx documentation for framework, located in http://developer.shotgunsoftware.com/tk-framework-qtwidgets
  • Added activity stream widget from the Shotgun Panel
  • Added global search widget from the Shotgun Panel
  • Added note input UI from the Shotgun Panel
  • Added playback label from the Shotgun panel
  • Added screengrab widget from the Shotgun panel

v2.0.6

Additional fixes and improvements as well as code tidy-up.

v2.0.3

Fix to the HierarchicalFilterProxyModel to support earlier versions of PySide

v2.0.2

Added additional widgets used by the File Manager and fixed various bugs

Details:

  • Added new widgets including a search control, an elided text label that can handle HTML and the navigation controls from the Loader.
  • Fixed numerous bugs in the grouped list view and hierarchical filtering proxy model

v2.0.1

Initial pre-release v2.x for testing with File Manager v2

v1.0.3

removing file_browser widget

v1.0.2

adding file browser widget

v1.0.1

Fixed PyQt 4.6.2 compatibility issue

Details:

  • Some old versions of PyQt don't contain the Q*Animation classes introduced in Qt 4.6 and this was causing some Toolkit features to fail
  • Updated to require core v0.14.58

v1.0.0

Initial release.

Follow

4 Comments

  • 0
    Avatar
    Philip Scadding

    shotgun_view = tank.platform.import_framework("tk-framework-shotgunutils", "shotgun_view")

    I don't think its meant to be shotgunutils anymore is it? Im guessing this is left over from before the frameworks were split out or is it for legacy? I also noticed that on the Shotgun utitilies framework page it also mentions finding out about the ShotgunOverlayWidget further down this page, but I presume it means this one now?

    thanks

    Phil

  • 0
    Avatar
    Manne Öhrström

    Thanks for the heads up - I'll update the docs! And yes, you are absolutely right - we basically just moved a bunch of stuff from the utils framework to the qtwidgets framework. It seemed like a better fit that way!

  • 0
    Avatar
    Philip Scadding

    Hi

    With this line:

    created_str = sg_item.get("created_at")

    In my tests this returns a float rather than the usual datetime. So I cant ask it for the date or the time.

    How can I get round this?

    thanks

    Phil

  • 0
    Avatar
    Manne Öhrström

    Hello!

    Check out the shotgunutils documentation for an explanation! Basically, because of serialization complexity issues, it turns out not to be straight forward to store datetime objects in the shotgun model (unfortunately!). Instead, we store unix time stamps. In order to convert these back to what you would get with the shotgun API, do the following: 

    import datetime
    from tank_vendor import shotgun_api3
    local_datetime = datetime.datetime.fromtimestamp(unix_time, shotgun_api3.sg_timezone.LocalTimezone())

    I have also updated the docs to say qtwidgets instead of shotgunutils in (hopefully) all the places where this was incorrect. Thanks! Manne

Please sign in to leave a comment.