From f95a287ed50ce5ad1fb5a33a32630f0c13a75ffe Mon Sep 17 00:00:00 2001 From: Jim Easterbrook Date: Mon, 10 Apr 2023 11:00:02 +0100 Subject: [PATCH 1/2] Fix region aspect ratio after adding to scene --- src/photini/__init__.py | 2 +- src/photini/regions.py | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/photini/__init__.py b/src/photini/__init__.py index ed812065..b5c9b30f 100644 --- a/src/photini/__init__.py +++ b/src/photini/__init__.py @@ -1,4 +1,4 @@ """Full documentation is at https://photini.readthedocs.io/""" __version__ = '2023.4.0' -build = '2658 (734002f)' +build = '2659 (24f2912)' diff --git a/src/photini/regions.py b/src/photini/regions.py index 50faf1b8..0a7ccb35 100644 --- a/src/photini/regions.py +++ b/src/photini/regions.py @@ -97,7 +97,6 @@ def set_style(self, draw_unit): pen.setColor(QtGui.QColor(0, 0, 0, 120)) pen.setWidthF(draw_unit * 5.5) self.setPen(pen) -## self.setBrush(QtGui.QColor(0, 0, 0, 40)) class RectangleRegion(QtWidgets.QGraphicsRectItem, RegionMixin): @@ -115,13 +114,15 @@ def __init__(self, region, display_widget, draw_unit, self.setRect(rect) self.highlight = QtWidgets.QGraphicsRectItem(parent=self) self.adjust_handles() - if self.aspect_ratio: - self.handle_drag(self.handles[3], self.handles[3].pos()) self.set_style(draw_unit) @catch_all def itemChange(self, change, value): scene = self.scene() + if scene and change == self.GraphicsItemChange.ItemSceneHasChanged: + if self.aspect_ratio: + self.handle_drag(self.handles[3], self.handles[3].pos()) + return if scene and change == self.GraphicsItemChange.ItemPositionChange: # limit move, in relative coords rect = self.rect() From 1ab398f7732c8e4f8f8dd3c9fd0c3fe784be7348 Mon Sep 17 00:00:00 2001 From: Jim Easterbrook Date: Wed, 12 Apr 2023 08:45:13 +0100 Subject: [PATCH 2/2] Update change log. --- CHANGELOG.txt | 7 +++++++ src/photini/__init__.py | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index cb312433..e4e0fee5 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -16,6 +16,13 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . +Changes in v2023.4.0: + 1/ Add "image regions" tab. + 2/ Connect image regions to Flickr / Ipernity "notes". + 3/ Add GPS coordinates to location / address data. + 4/ Improved XMP metadata handling. + 5/ Other minor improvements and bug fixes. + Changes in v2023.2.0: 1/ Add Pixelfed / Mastodon uploader. 2/ GPX importer sets altitude as well as latitude & longitude. diff --git a/src/photini/__init__.py b/src/photini/__init__.py index b5c9b30f..77d4f121 100644 --- a/src/photini/__init__.py +++ b/src/photini/__init__.py @@ -1,4 +1,4 @@ """Full documentation is at https://photini.readthedocs.io/""" __version__ = '2023.4.0' -build = '2659 (24f2912)' +build = '2660 (f95a287)'