Commit Graph

11 Commits

Author SHA1 Message Date
Christian Stenger
6a1d678db7 Wizards: Fix typo
Amends 829faf7eef.

Change-Id: Id09b5eca3a2c6a4a90d4402383723b8a03a59594
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-05-20 14:37:06 +00:00
Christian Kandeler
829faf7eef File wizards: Optionally show the default suffix
In wizards that create a single new file, there's almost always a
default suffix that gets appended if the user provides only the base
name. However, there's currently no visual indication on the page that
such a suffix will be appended. Therefore, we add an optional field to
the FileWizardPage that displays the default suffix if the wizard
provides one.

Change-Id: Ia1c8966e7de14b484d065dbd4a41aa74f484f085
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-03-10 09:53:53 +00:00
Christian Stenger
6288e03264 Wizards: Fix regular expressions
Although this is valid JavaScript matching the '.' is
not working as expected.
The directory always gets messed up by replacing the
first character with a dash. Use an alternate regular
expression and also ensure the replacement happens
globally instead of once as we want to replace all
dots by a dash.
As at it fix handling of the file suffixes as well.

Task-number: QTCREATORBUG-22625
Change-Id: Ide189fe50e29994abfb368e503050b9b413aba9f
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2019-06-27 07:18:19 +00:00
Christian Gagneraud
3b596eef40 JSON wizard: Fix invalid json files
share/qtcreator/templates/wizards/projects/vcs/git/wizard.json:
Invalid \escape: line 16 column 59 (char 574)
Loading share/qtcreator/templates/wizards/files/java/wizard.json:
Invalid \escape: line 12 column 137 (char 466)

Change-Id: I2aeed7d5e167b92a1d118678d112f4a568c59997
Fixes: QTCREATORBUG-22432
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-05-13 07:40:41 +00:00
Christian Stenger
4f989d6543 Wizards: Fix java file wizard
Avoid ending up with a wrong named class when specifying the
file name instead of the class name.

Change-Id: I5e2ddaae1a16d60aa40fb9303e8d49efa9f51b7e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2019-05-10 05:47:17 +00:00
Eike Ziller
e0d38ae414 Export Wizard values to JavaScript macro
Registers a new function "value('name')", available to the wizard json
files, which returns the value of the variable "name" as a JavaScript
object. So, variables with a string value are actual JavaScript strings,
booleans are booleans, lists are lists, and dictionaries are
dictionaries.

The patch also makes it actually possible to assign JSON lists and
dictionaries to values.

This removes some hacks involving creating complex JavaScript objects
through string substitution.

Change-Id: I4ac6da22bc5bccc9fadee97694c2fa14d44c9307
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-05-09 11:19:43 +00:00
Alessandro Portale
9113125a5e Wizards: Add file extension as text overlay to some wizards
Change-Id: Ibfd1144271c4381c7125db80713cbde431a54cf7
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2017-07-24 15:32:24 +00:00
Tim Jenssen
ffe305527b Wizards: remove default icon
Change-Id: I665ccb887294885758b45b0bd272620e1a796eec
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2016-11-10 15:45:09 +00:00
Tobias Hunger
aa37df645d JsonWizard: Update to use supportedProjectType
Remove "kind" as that is no longer necessary (even though it is still
handled if that is in the wizard).

Change-Id: I3e56d5e0d936b622dae5091950427f9b2db60695
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-01-19 15:20:55 +00:00
Tobias Hunger
f1f2475d3e JsonWizard: split plugins and features when considering enabled state
Now that we have the infrastructure to handle both separately it makes
no more sense to merge them.

Change-Id: Ia2694eef60c0fe17b025e4d6766c7a8f775513f5
Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
2015-05-28 15:50:24 +00:00
Tobias Hunger
ed8a9cba2b JsonWizard: Replace Java wizard with JsonWizard
Change-Id: I93fc26e48b39635662662a9ab4040f45fa874876
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-09-30 17:29:08 +02:00