Skip to content

Commit

Permalink
Merge branch 'transparent_bg' into 'master'
Browse files Browse the repository at this point in the history
Transparent backgrounds behind view

See merge request plom/plom!440
  • Loading branch information
cbm755 committed May 13, 2020
2 parents 7678803 + 84d8ad4 commit 3f315b0
Show file tree
Hide file tree
Showing 5 changed files with 67 additions and 65 deletions.
4 changes: 2 additions & 2 deletions plom/client/backGrid.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,5 @@ def __init__(self, username=None):
x in username.lower() for x in ["omer", "remo", "legna", "angel"]
):
self.setTexture(QPixmap(os.path.join(base_path, "backGrid2.png")))
else:
self.setTexture(QPixmap(os.path.join(base_path, "backGrid1.svg")))
# else:
# self.setTexture(QPixmap(os.path.join(base_path, "backGrid1.svg")))
124 changes: 62 additions & 62 deletions plom/client/backGrid1.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed plom/client/backGrid3.png
Binary file not shown.
1 change: 1 addition & 0 deletions plom/client/examviewwindow.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ def __init__(self, fnames):

def initUI(self, fnames):
# set background
self.setStyleSheet("background: transparent")
self.setBackgroundBrush(BackGrid())
self.setRenderHint(QPainter.Antialiasing, True)
self.setRenderHint(QPainter.SmoothPixmapTransform, True)
Expand Down
3 changes: 2 additions & 1 deletion plom/client/pageview.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ def __init__(self, parent, username=None):
# Set scrollbars
self.setVerticalScrollBarPolicy(Qt.ScrollBarAsNeeded)
self.setHorizontalScrollBarPolicy(Qt.ScrollBarAsNeeded)
# set the area outside the groupimage to be tiled grid png
# set the area outside the groupimage to be tiled grid image
self.setStyleSheet("background: transparent")
self.setBackgroundBrush(QBrush(BackGrid(username)))

# Nice antialiasing and scaling of objects (esp the groupimage)
Expand Down

0 comments on commit 3f315b0

Please sign in to comment.