Some antialias/smoothing finetuning

This commit is contained in:
Rebecca Breu 2023-11-28 18:09:57 +01:00
parent 752ca47da7
commit c66ec67fe1
3 changed files with 5 additions and 4 deletions

View file

@ -10,9 +10,9 @@ Added
behaviour can be changed to always use PNG (the former behaviour) or
always JPG. To apply this behaviour to already saved images in
existing bee files, you can save them as new files.
* Antialias/smoothing for displaying images. (For images being
displayed at a large zoom factor, smoothing will turn off to make
sure that icons, pixel sprites etc can be viewed correctly.)
* Enable antialiasing/smoothing. Images that are being displayed at a
large zoom factor are exempt to make sure that icons, pixel sprites
etc can be viewed correctly.
* A scene can now be exported to a single image (File -> Export Scene...)

View file

@ -301,7 +301,7 @@ class BeePixmapItem(BeeItemMixin, QtWidgets.QGraphicsPixmapItem):
painter.drawRect(rect)
def paint(self, painter, option, widget):
if painter.combinedTransform().m11() < 3:
if painter.combinedTransform().m11() < 2:
# We want image smoothing, but only for images where we
# are not zoomed in a lot. This is to ensure that for
# example icons and pixel sprites can be viewed correctly.

View file

@ -50,6 +50,7 @@ class BeeGraphicsView(MainControlsMixin,
self.setBackgroundBrush(
QtGui.QBrush(QtGui.QColor(*constants.COLORS['Scene:Canvas'])))
self.setRenderHint(QtGui.QPainter.RenderHint.Antialiasing)
self.setFrameShape(QtWidgets.QFrame.Shape.NoFrame)
self.undo_stack = QtGui.QUndoStack(self)