Commit Graph

138 Commits

Author SHA1 Message Date
Eugene Sandulenko
5b3b73c523 GUI: Added icon to clear button. Reverted PNG support 2011-10-24 05:18:49 +01:00
Eugene Sandulenko
59474ca128 GUI: Replaced search icon with a better looking one.
Icons are by Yusuke Kamiyamane. http://p.yusukekamiyamane.com/
2011-10-23 23:44:14 +01:00
Eugene Sandulenko
4c08fccf58 GUI: Add support for PNG images in themes 2011-10-23 23:44:14 +01:00
Eugene Sandulenko
ed2cb9a6b3 GUI: Added debug ouput for determining loaded theme 2011-10-19 13:48:01 +01:00
Chris Warren-Smith
ed07b99b22 BADA: Misc changes merged from appstore release 2011-10-18 23:22:25 +10:00
Johannes Schickel
fa5f8dc703 GRAPHICS: Rename NewFont to BdfFont. 2011-07-01 21:53:01 +02:00
Johannes Schickel
8201df7bb6 GRAPHICS: Move NewFont code to a separate file. 2011-07-01 21:10:25 +02:00
Thierry Crozat
6b13782967 GRAPHICS: Move genLocalizedFontFilename() to FontManager class
It was defined in ThemeEngine class , but I moved it to make it
possible to use localized font in other places.
2011-06-06 23:20:09 +01:00
Max Horn
91b889e2d3 COMMON: Rename kFeatureCursorHasPalette -> kFeatureCursorPalette 2011-06-04 11:55:56 +02:00
strangerke
69b1485a22 GIT: Clean up: Suppress SVN tags, now useless 2011-05-12 01:16:22 +02:00
Johannes Schickel
473337effd GUI: Allow .zip files with case differing from ".zip" as theme files too.
Formerly our code used "hasSuffix" to check for a ".zip" suffix. Since
hasSuffix does a case-sensitive match that would not work, in case the file
was called "scummmodern.ZIP" instead of "scummmodern.zip" for example.

To fix that I am using a case-insensitive matchString instead now.
2011-05-07 15:49:57 +02:00
Johannes Schickel
16f1b51e2a GUI: Clean up localized font filename generation. 2011-05-05 20:07:37 +02:00
Johannes Schickel
71bdb86e02 Merge pull request #16 "Add a PixelFormat to Graphics::Surface.".
For further discussion check here:
https://github.com/scummvm/scummvm/pull/16

Conflicts:
	graphics/png.cpp
2011-05-01 16:54:45 +02:00
Ori Avtalion
9414d7a6e2 JANITORIAL: Reduce header dependencies in shared code
Some backends may break as I only compiled SDL
2011-04-28 15:08:58 +03:00
Max Horn
759cac0abc GUI: Fix warning on systems where char is unsigned 2011-04-26 14:24:47 +02:00
Littleboy
ea9774f689 GUI: Add basic validity check to ThemeEngine::themeConfigParseHeader (workaround for #3103051)
When loading a corrupted zip, the data returned for THEMERC will be garbage, which will cause an assert in isspace() when trying to trim the data.
This checks that the first character of the header is in the range [0;127] and bails out if not.
2011-04-24 22:45:36 -04:00
Johannes Schickel
2329a00873 GUI: Prefer Surface::create taking a PixelFormat over the one taking a byte depth. 2011-04-17 16:34:58 +02:00
Johannes Schickel
28e6859a69 GUI: ThemeEngine.cpp/.h formatting fixes. 2011-04-03 15:04:20 +02:00
dhewg
ff11ab284a Revert "GUI: Properly clear the screen buffer"
This reverts commit c8551b80dd.

Turns out the flicking comes from an updateScreen() call in
android's clearScreen(). Besides, this broke GMM... a little
2011-02-25 00:08:46 +01:00
dhewg
a017cb3d00 GUI: Fix two-step rendering
This is used when changing directories in the 'add game' dialog or when
choosing another tab in the option dialog. Only blit to the overlay on
the final pass. Gets rid of highly annoying flickers on androids
2011-02-24 23:18:34 +01:00
dhewg
c8551b80dd GUI: Properly clear the screen buffer
Don't operate on the overlay, it might be a pointer to a texture
used by the hardware. This get's rid of some annoying flickers on
androids
2011-02-24 23:18:34 +01:00
Johannes Schickel
7b8b73f64a GUI: Update cursor palette handling for RGBA->RGB change. 2011-02-14 17:08:32 +01:00
Jordi Vilalta Prat
8393bc5b5f I18N: Don't build TranslationManager when translation is disabled.
svn-id: r54684
2010-11-30 18:50:19 +00:00
Max Horn
3450f47667 GUI: Fix bug in ThemeEngine::addFont related to localized fonts
Basically, it was remembering the font under its non-localized name.
This resulted in a leak, and potentially could have caused the wrong
font to be used in a localization.

svn-id: r54256
2010-11-15 23:52:06 +00:00
Max Horn
8799db594e GUI: Tweak ThemeEngine methods to use Common::String params & const qualifier
svn-id: r54255
2010-11-15 23:51:46 +00:00
Jordi Vilalta Prat
8388e0dfea JANITORAL: Clean trailing whitespaces.
svn-id: r53160
2010-10-12 02:18:11 +00:00
Max Horn
a0c0b934c7 GUI: Replace GUI_ENABLE_BUILTIN_THEME by DISABLE_GUI_BUILTIN_THEME
svn-id: r52936
2010-09-28 20:31:17 +00:00
Thierry Crozat
b1f63deba3 GUI: Partial fix to bug #3075649 Fonts not found with buit-in theme
When the locale font are not found when loading the theme, it now
fallbacks to default language (i.e. English) and default font. For this to work
I had to move the TranslationManager initialization before the Theme is
loaded. Therefore it is now initialized when the GuiManager is constructed.

svn-id: r52896
2010-09-25 22:47:00 +00:00
Johannes Schickel
2a353089aa GUI: Remove dead code.
This code was added when tooltip support was added. Since we changed the way
how tooltips are drawn later on, this code is not required anymore. Actually
it was never used, but it could've been used to save/restore the state of the
GUI for the tooltips.

svn-id: r52717
2010-09-14 00:34:12 +00:00
Thierry Crozat
1f986e14af i18n: Add lowres context in a few places.
I also changed the english text for the GUI Renderer items in 1x mode
as the text was tool long and cut.

svn-id: r52683
2010-09-12 11:43:51 +00:00
Thierry Crozat
37027d6531 I18N: Add "lowres" context for several GUI strings when in 1x mode.
This enables translators to use a different translation for these strings in
1x mode (e.g. 320x200 or 320x240) and in 2x or 3x modes.

svn-id: r52461
2010-08-30 22:24:40 +00:00
Thierry Crozat
769ad3109d GUI: fix crash when localized font could not be found
The ThemeEngine had a fallback implemented to use the
non-localized font if the localized one (e.g. for Hungarian) could not
be found. However the fallback was not working. Now it is working. 

svn-id: r52243
2010-08-20 21:50:58 +00:00
Johannes Schickel
2095ce31bd GUI: Fix loading BDF fonts from theme archives.
svn-id: r51585
2010-08-01 19:31:18 +00:00
Eugene Sandulenko
ccbb12b1cb GUI: Fix overdrawn tabs
If tabs are scrolled, do not draw those which are supposed to be invisible.

svn-id: r51268
2010-07-24 22:54:56 +00:00
Eugene Sandulenko
d6695e180c GUI: Fix tooltip drawing
With help of Tanoku tooltips were switched from widgets to dialogs
which helped to fix nasty bug with background not being restored.
Although it is basically a hack around inconsistent font backbuffering
in our GUI code, for the time being it is feasible.

The patch was extended with way to specify tooltip background in the
theme file.

svn-id: r51217
2010-07-23 19:36:47 +00:00
Johannes Schickel
e5e94d4511 Strip trailing whitespaces in our common code base.
svn-id: r51094
2010-07-21 18:17:51 +00:00
Max Horn
9977e2db90 GUI: Enhance ThemeEngine to find theme .zip files using SearchMan
This is based on the Android specific patch found under:
backends/platform/android/scummvm-android-themeengine.patch
After some testing we should be able to get rid of that custom patch.

svn-id: r51028
2010-07-19 14:28:46 +00:00
Robert Špalek
5e030bebcc enable reading ZIP archives even without USE_ZLIB
our module unzip.cpp can read uncompressed ZIP archives even without zlib.  if some of the files
inside are compressed and zlib is not linked in, an error is returned.

svn-id: r50483
2010-06-29 06:38:00 +00:00
Eugene Sandulenko
0e7ccb896d i18n: Add support for locale-dependent fonts
Currently it ws not decided where to put fonts, but if you put BDF files into
themepath, they will get picked up.

The font name has to contain same codepage specification as in the .po file,
i.e. fixed5x8-iso-8859-5.bdf for Cyrillic codepage. In case the font does not
exist, default will be used.

All built in fonts get proper names.

TODO: Currently there is a bug with our font cacher. Font clR6x12-iso-8859-5
is empty after loading from FCC file. Reason is unknown.

svn-id: r50448
2010-06-28 15:17:10 +00:00
Eugene Sandulenko
01f9006ee7 GUI: Implement tooltips. FR #2821513.
FR #2821513: "GUI: add tooltips".
Added tooltips for Add Game button, clear field buttons and couple
other.

Current problem: Only first call correctly restores text. I could
not find where restore information gets lost.

svn-id: r49774
2010-06-15 10:52:35 +00:00
Eugene Sandulenko
dc040aa867 GUI: Implement radiobuttons.
Implement radiobuttons in GUI. Also closes FR #2821529:
"GUI: volume and subtitles speed sliders".

Subtitle toggle button is replaced by three radiobuttons grouped
by a single group.

Updated translations and themes.

svn-id: r49767
2010-06-15 10:48:39 +00:00
Eugene Sandulenko
859212df25 Implement translation support for ScummVM GUI.
Based on patch #2903830: "Updated Translation Prototype" by alexbevi
which in turn is based on patch #1739965 by jvprat.

Currently it builds all translations right into ScummVM. Once the
feature will be accepted more widely, i.e. more translations will
pop up, it will be trivial to move translation strings to external
file.

Finished translation: Russian
Unfinished translation: Hungarian

Things which are nice to do:
 - Language code -> language mapping for more user friendness
 - Specifying fonts to be used with language
 - Updating of interface language without restart. It will require
   moving of much code to reflowLayout() methods for each dialog

The .po files must be in single byte encodings. I.e. no support
for Unicode.

svn-id: r49759
2010-06-15 10:44:51 +00:00
Johannes Schickel
38b2b3c04f Move StringTokenizer to its own files (tokenizer.h/tokenizer.cpp).
svn-id: r48310
2010-03-20 12:56:56 +00:00
Max Horn
8ac5d00d57 Hide ZipArchive implementation, only expose it via factory functions: makeZipArchive()
svn-id: r48040
2010-02-13 11:56:30 +00:00
Max Horn
6c98169dc3 GUI: Shorten button labels if too long, and improve the shortening logic
svn-id: r46381
2009-12-15 08:19:59 +00:00
Max Horn
d60b5ca516 Include font.h instead of fontman.h in places that don't need fontman :)
svn-id: r46311
2009-12-09 16:46:14 +00:00
Max Horn
2bbf708dea Introduced new type Common::DisposeAfterUse::Flag
svn-id: r45233
2009-10-18 19:41:59 +00:00
Max Horn
d0876b06ed Remove some unused variables
svn-id: r44853
2009-10-09 22:21:45 +00:00
Max Horn
3399c3aeb6 Change doxygen inline comments from "//!" to "///" as proposed on -devel
svn-id: r44802
2009-10-08 21:28:57 +00:00
Max Horn
f242266f6d Change a couple places from 'end of namespace' to 'End of namespace', for consistency
svn-id: r44634
2009-10-04 21:26:33 +00:00