Setting the global palette is not a very good idea, because
it interferes with native styling.
On Windows 7 the dark theme was unuasable, because the text on
all natives controls was to bright.
All native controls and the global palette should be left alone.
Wherever we want styling/theming we have to use Manhatten style.
Change-Id: Ia1d0bfb190e4bde7be72f751afc0846570c1189d
Reviewed-by: hjk <hjk121@nokiamail.com>
Adds a 'Theme' tab to the environment settings and a '-theme' command
line option.
A theme is a combination of colors, gradients, flags and style
information.
There are two themes:
- 'default': preserves the current default look
- 'dark': uses a more flat for many widgets, dark color theme
for everything
This does not use a stylesheet (too limited), but rather sets
the palette via C++ and modifies drawing behavior.
Overall, the look is more flat (removed some gradients and bevels).
Tested on Ubuntu 14.04 using Qt 5.4 and running on a KDE
Desktop (Oxygen base style).
For a screenshot, see
https://gist.github.com/thorbenk/5ab06bea726de0aa7473
Changes:
- Introduce class Theme, defining the interface how to access theme
specific settings. The class reads a .creatortheme file (INI file, via
QSettings)
- Define named colors in the [Palette] section
(see dark.creatortheme for example usage)
- Use either named colors of AARRGGBB (hex) in the [Colors]
section
- A file ending with .creatortheme may be supplied
to the '-theme' command line option
- A global Theme instance can be accessed via creatorTheme()
- Query colors, gradients, icons and flags from the theme
were possible (TODO: use this in more places...)
- There are very many color roles. It seems better to me
to describe the role clearly, and then to consolidate later
in the actual theme by assigning the same color.
For example, one can set the text color of the output pane button
individualy.
- Many elements are also drawn differently.
For the dark theme, I wanted to have a flatter look.
- Introduce Theme::WidgetStyle enum, for now {Original, Flat}.
- The theme specifies which kind of widget style it wants.
- The drawing code queries the theme's style flag and
switches between the original, gradient based look and
the new, flat look.
- Create some custom icons which look better on dark background
(wip, currently folder/file icons)
- Let ManhattanStyle draw some elements for non-panelwidgets, too
(open/close arrows in QTreeView, custom folder/file icons)
- For the welcomescreen, pass the WelcomeTheme class.
WelcomeTheme exposes theme colors as Q_PROPERTY accessible from
.qml
- Themes can be modified via the 'Themes' tab in the environment
settings.
TODO:
* Unify image handling
* Avoid style name references
* Fix gradients
Change-Id: I92c2050ab0fb327649ea1eff4adec973d2073944
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
Reviewed-by: hjk <hjk121@nokiamail.com>
The expander is used in the wizards, and being able to specify
timestamps is something many people requested at devdays.
Change-Id: If227f9c48d0b5f409d22233af8c43ae376f343f9
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
Remove usage of the Q_EXPORT_PLUGIN macros, which do not exist in Qt 5.
Change-Id: I678c3cf10b9c5d5c1b9f252b0ecd1c97dc810a47
Reviewed-by: hjk <hjk121@nokiamail.com>
Reviewed-by: Christian Stenger <christian.stenger@digia.com>
and avoid putting those objects into the object pool.
Change-Id: I46c5ed93a9e80532b3cbd7dba2e52b28b1595aa3
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
Locator's and Find's extensionsInitialized functions were called before
the mainwindow's extensionsInitialized function before the plugins were
merged in one.
Task-number: QTCREATORBUG-11399
Change-Id: I49baac4f9127f75d9650ce11e53327b07775eba0
Reviewed-by: hjk <hjk121@nokiamail.com>
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
A lot of our build system files specify unneeded include
paths. These roughly fall into the following categories:
a) Paths that are already set in more general files
such as qtcreator.pri.
b) Paths that serve no purpose at all, possibly
left over from earlier versions of the project.
c) Paths that act as workarounds for wrong include
statements of the form '#include "xyz.h"', where
xyz.h is not in the same directory as the including
file.
This patch removes such path specifications and fixes the offending
include statements from case c).
Tested on Linux, Windows and OSX with qmake and qbs.
Change-Id: I039a8449f8a65df0d616b4c08081145c18ae4b15
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
A few details are still to be done:
- extra windows are not restored yet
- window title of extra windows should show information about current
editor
- the "raise main window" hack for Linux doesn't work with Qt 5
But it should already now be quite usable.
Change-Id: I638583ee4b2abe32e95c261bdf31b4a10b472748
Reviewed-by: David Schulz <david.schulz@digia.com>
qrand() is used in several places, but it is only seeded in ToolSettings
Change-Id: I72ed3b96315081384c63572566d31dea1a8f8b69
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
When a new file was created from the file menu, the permissions
on *nix was always 0600 regardless of the proess' current umask.
Fixed by letting CorePlugin::initialize() initialize the umask in
Utils::SaveFile. Since getting the system's umask is not thread
safe this can't be done directly in SaveFile::open.
Task-number: QTCREATORBUG-6513
Change-Id: I10d8b2f4ab85574ed3004b5e646664c2255196b9
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Broke while fixing the flag handling in editor manager.
Change-Id: Id743de099b3c193dcbf1dc55b4372217c691488a
Reviewed-by: David Schulz <david.schulz@digia.com>
Getting the #include directives ready for Qt5. This includes the
new-project wizards.
Change-Id: Ia9261f1e8faec06b9285b694d2b7e9a095978d2b
Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
And use it for some of the plugins. It avoids the plugins to
do the timing on their own, and actually adds guarantees about
the order the delayed initialization is done.
Change-Id: I88ad9b46b24b82c91509774170fe0e7e99e88e4b
Reviewed-by: Tobias Hunger <tobias.hunger@nokia.com>
Presentation mode can be entered by passing -presentationMode when
starting Qt Creator.
It displays a popup with the keyboard shortcut of the commands
that are triggered. Great for the DevDays;-)
Change-Id: I897966aab491f98e2a5abc4433c40b04e2a8db57
Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
Reviewed-by: Liang Qi <liang.qi@nokia.com>
Creates a new page in the options dialog which allows
the user to modify MIME type's globl patterns and rule-based
magic matchers.
As a side-effect of this feature our MIME database (and related
components) got some improvements.
Reviewed-by: Friedemann Kleint
And make use of it to accept on the command line the patterns:
"filename" "+45", "filename" ":23", "filename:12" and "filename+42"
Task-Nr: QTCREATORBUG-2428