aboutsummaryrefslogtreecommitdiff
path: root/gui/ThemeEngine.cpp
AgeCommit message (Collapse)Author
2019-10-03GUI: Add Missing Switch Default CasesD G Turner
These are flagged by GCC if -Wswitch-default is enabled.
2019-09-01TTS: Make sure that TTS lang matches transMan langJaromir Wysoglad
2019-08-03GUI: Fix scrollbarsAlexander Tkachev
- removed +1px in ListWidget, added in lordhoto's 2007 commit 68eb28a (aka r29971 in svn) `Fix for bug #1670082 "GUI: Modern theme gfx glitch in launcher".`, because it made clip this last line of scrollbar in all themes, which doesn't look good. In 2007 theme was written in .ini, which is not the case now. I don't see any glitches after removing this "fix"; - fixed how scrollbar top and bottom scroll buttons are drawn in ThemeEngine::drawScrollbar: there were these weird magic numbers, but in reality extra space that buttons should occupy is hardcoded in scrollbar.cpp (ScrollBarWidget) and is just +1px.
2019-07-30GUI: Rewrite Cloud tabAlexander Tkachev
- StorageWizardDialog is removed, along with bmps it was using; - EditTextWidget now accepts custom font in constructor; - ScrollContainer scrollbar now jumps to top when content height changes so it's "overscrolled"; - IndexPageHandler now does not awaits for `code` GET-parameter, as local webserver is no longer used to connect Storages; - CloudManager and all corresponding Storages are updated to support disconnecting and to notify about successful connection.
2019-04-02BUILD: Update default theme to use remasteredMatan Bareket
2019-03-12GUI: Fix loading new (not already cached) localized fontsThanasis Antoniou
2019-01-22GUI: Don't try loading TTF fonts for themes that don't request oneBastien Bouclet
2018-12-25GUI: Attempt to load fonts from fonts.dat if they aren't present in the ↵Cameron Cawley
theme archive
2018-07-24GUI: Fix scrollbar bottom arrow being displayed as up arrow after mouse upThierry Crozat
2018-07-22GUI: Use consistent capitalization for optionsThierry Crozat
As discussed on the mailing list we should use title capitalization only for push buttons and tabs and use sentence capitalization for everything else.
2018-04-19GUI: Unify clip and non-clip draw callsBastien Bouclet
2018-04-19GUI: Remove alpha bitmap supportBastien Bouclet
It was never used since its introduction 4 years ago It was not updated to work with the clipping rect
2018-03-12GUI: Remove the ThemeItem draw queuesBastien Bouclet
Drawing nows happens directly when the Dialog or Widget draw methods are called. This makes it easy to debug why a particular low level draw method was called, by inspecting the call stack. This replaces the notion of "buffering" by two independant ways to control what is drawn and where: - The active layer is used to select whether the foreground or background part of the dialogs are rendered by the draw calls. - The active surface is used to select if the draw calls affect the back buffer or the screen. The foreground layer of the active dialog is drawn directly to the screen. Its background layer is drawn to the back buffer. This way widgets can restore the back buffer in order to update without having to redraw the dialog's background. Dialogs lower in the dialog stack are drawn entirely to the back buffer.
2018-01-27GUI: Remove the parent from the button_idle DrawDataBastien Bouclet
Removing it does not result in any visible difference. It was likeliy set by mistake.
2017-08-06GUI: Mark some fall-through cases as intentionalBastien Bouclet
Comments explain how the num lock handling works before the fall-through cases.
2017-06-20GUI: Separate bevel and shadow effect when extending widget rectThierry Crozat
When widget::draw() is called it asks the ThemeEngine to redraw the background first and then the widget gets redrawn in drawWidget(). The ThemeEngine uses an extended rect to restore the background to include bevel and shadow effects. However if this extended rect overlaps with other widgets, since those other widgets are not redrawn, a part of those will be missing. See for example bug #6394: GUI: List View save page drawns over font. In case we get overlap we might need to change the way widgets are drawn so that all widgets intersecting the area where the backgroud is restored are redrawn. This commit simply seperate the bevel and shadow effects, and uses the shadow offset only to extend the bottom and right sides of the rectangle (while the bevel offset is still used to extend all four sides). This results in a smaller extended rectangle (if the shadow offset is bigger than the bevel offset, which is the case of the list view) and thus decrease the risk of the issue happening. The particular cases described in bug #6394 are all fixed with this change.
2017-04-06GUI: Restore settings if GUI cannot be renderedJoseph-Eugene Winzer
PR#921 changes the behavior of the client that if the GUI fails to be rendered the previously applied settings in the misc category are restored. Error messages were altered according to the changes. Bug: #9717 GUI: Indirectly changing 'GUI Language' can produce inconsistent behaviour when changing some options.
2017-03-09GUI: Fix resolution of theme filename to idJoseph-Eugene Winzer
getThemeId() returned "builtin" for valid filenames because FSNode only searches for the theme filename, like "scummmodern.zip" in the current directory. listUsableThemes() searches SearchMan default directories for theme files.
2017-02-28GUI: Check rect validity for popup/radio drawingWillem Jan Palenstijn
2017-02-28GUI: Give each tab in TabWidget its own widthWillem Jan Palenstijn
The width of each tab is now computed from its title, independently of the other tabs. This increases the number of tabs that fit on the screen. This rewrite also fixes a bug where if the window size increased while _firstVisibleTab > 0, some tabs would become inaccessible when the scroll buttons were hidden. The layout key Globals.TabWidget.Tab.Width is now treated as minimal tab width. This is set so that the tabs fit reasonably well in lowres layouts. At the same time, this reduces the lowres scroll buttons heights to fit. This patch makes the Nintento DS hacks in TabWidget obsolete. (Hopefully! I'm not able to test.)
2017-01-12GUI: Fix Unused Variable Compiler Warning when USE_PNG not set.D G Turner
2016-08-24GUI: Add Storage providers logosAlexander Tkachev
StorageWizardDialog now shows logo of the Storage being connected (in modern highres theme).
2016-08-24GUI: Add "Paste" button in StorageWizardDialogAlexander Tkachev
It pastes clipboard contents as code into 8 fields of that dialog. (Clipboard support works with SDL2 only.) "Open URL" and "Paste" buttons are placed in the left column under the picture (because there is no room for 4 buttons in the bottom row). Commit also adds "dropbox.bmp", which is just a square 115x115 picture. Such pictures are would be used as Storages logos in that dialog. In lowres there is no left column, so all 4 buttons are in the same row. None of them are visible, because they are overflowed. Container has to be added to continue working on them.
2016-08-24GUI: Fix warningsEugene Sandulenko
2016-08-24GUI: Fix texts clippingAlexander Tkachev
If it was completely clipped out (empty rectangle), it was drawing the whole text ("empty means no clipping"), so I had to detect such cases and change textArea to one small pixel.
2016-08-24GUI: Added transparency to PicWidgetsEugene Sandulenko
2016-08-24GUI: Added empty dialog backgroundEugene Sandulenko
2016-08-24GUI: Added possibility to specify scale mode for AlphaBitmapsEugene Sandulenko
2016-08-24GUI: Implemented more modes to autoscaleEugene Sandulenko
2016-08-24GUI: Implemented alphabitmap autoscaleEugene Sandulenko
2016-08-24GUI: Implemented possibility to use alphabitmaps in GraphicsWidgetEugene Sandulenko
2016-08-24GUI: Added new alphabitmap image typeEugene Sandulenko
2016-08-24GUI: Added support for PNG imagesEugene Sandulenko
2016-07-03JANITORIAL: Remove trailing spacesAlexander Tkachev
2016-07-03GUI: Use clipping everywhereAlexander Tkachev
2016-07-03GUI: Fix blitAlphaBitmapClip()Alexander Tkachev
2016-07-03GUI: Add blipClip()Alexander Tkachev
2016-07-03GUI: Add drawTabClip()Alexander Tkachev
2016-07-03GUI: Add drawSquareClip()Alexander Tkachev
2016-07-03GUI: Add VectorRendererSpec::drawTriangleClip()Alexander Tkachev
2016-07-03GUI: Fix ThemeItemTextData's dirty rectangleAlexander Tkachev
2016-07-03GUI: Make PopUpWidget clipAlexander Tkachev
2016-07-03GUI: drawRoundedSquareClip()Alexander Tkachev
2016-07-03GUI: clippingRect propagated deeperAlexander Tkachev
2016-07-03GUI: Prepare button to be clippedAlexander Tkachev
2016-07-03GUI: Add ScrollContainerAlexander Tkachev
2016-07-03GUI: Use boss's x/y/w/h instead of clippingAreaAlexander Tkachev
2016-06-06GUI: Fix regressionEugene Sandulenko
2016-06-06GUI: Fixed negative index checkEugene Sandulenko
2016-06-05GUI: Prevent potential negative index accessEugene Sandulenko