[Qt-creator] How can I make a global cpp code style config
Ziller Eike
Eike.Ziller at theqtcompany.com
Thu Jun 18 12:22:20 CEST 2015
> On Jun 17, 2015, at 3:12 PM, Miller Henry <MillerHenry at JohnDeere.com> wrote:
>
> I’m packaging qt creator for my company, and I want to make our coding style rules the default. Creating the .xml style is easy enough, but I can’t seem to find a way to get this as the default style.
>
> We are installing qt creator into /opt/QtCreator, and we have working template wizards installed into /opt/QtCreator/share/qtcreator/templates/wizards . I expect that I just need to install QtCreator.ini into /opt/QtCreator/share/qtcreator/QtProject/ and our code style .xml into /opt/QtCreator/share/qtcreator/QtProject/codestyles/Cpp/. This doesn’t seem to work though – qt creator doesn’t seem to pick up the style. Is there something more that I’m missing?
Hi,
as far as I can see, there is setting for “default” coding style. That means, that if you add something like
[CppCodeStyleSettings]
CurrentPreferences=@ByteArray(mycodingstyle)
to the “install settings” (/opt/QtCreator/share/qtcreator/QtProject/QtCreator.ini looks correct to me), then this will set the coding style only if there are no user settings at all.
I.e. when running Qt Creator with a clean settingspath (e.g. with -settingspath /tmp/foosettings).
--
Eike Ziller, Senior Software Engineer - The Qt Company GmbH
The Qt Company GmbH, Rudower Chaussee 13, D-12489 Berlin
Geschäftsführer: Mika Pälsi, Juha Varelius, Tuula Haataja
Sitz der Gesellschaft: Berlin, Registergericht: Amtsgericht Charlottenburg, HRB 144331 B
More information about the Qt-creator
mailing list