Commit Graph

9 Commits

Author SHA1 Message Date
hjk
473a741c9f Utils: Rename FileName to FilePath
More in line with QFileInfo terminonlogy which appears to be
best-of-breed within Qt.

Change-Id: I1d051ff1c8363ebd4ee56376451df45216c4c9ab
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-05-28 12:23:26 +00:00
Nikolai Kosjar
8782414984 ClangTools: Remove unused variable
Change-Id: Idc361f1aa969fa14f0268f14ad405abbfcd6d92c
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2019-02-22 08:15:50 +00:00
Ivan Donchevskii
9bcc871ece ClangFormat: Format multiple text ranges at once
'reformat' function in LibFormat accepts mutilple ranges.
Let's provide the ranges for the same file together when
formatting on save and formatting after fix-its.

Change-Id: I27789da83a1efc27beb57acf238508a191562bb9
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2019-02-19 07:33:13 +00:00
Ivan Donchevskii
d7058e1afe ClangFormat: Refactor indenter to allow ClangFormat unit-tests
We do not build texteditor files in unit-tests so some tricks
were required to make ClangFormatIndenter available.

First simple unit-test proofs it builds and runs.

Change-Id: I81d5ea099bd27fd1c1ed8b5b7877299dcc62a67f
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2019-01-22 09:52:15 +00:00
Bernhard Beschow
4c69ec5b89 ClangTools: Fix compilation
Amends 97d3858720.

Change-Id: I3da79ca3cdc907a6fed7cfe64e7f8f61efc40948
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2018-12-21 13:33:09 +00:00
Ivan Donchevskii
97d3858720 ClangTools: Apply indention/formatting after fix-its
Fix-its do not follow the current formatting style therefore
apply indention/formatting by using indenter.

This change will work best when ClangFormat plugin is
enabled to not only reindent line but also format it.

Task-number: QTCREATORBUG-21448
Change-Id: I8bcafcf49f3118aff7840326547e7a24052469b2
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2018-12-21 08:04:56 +00:00
Orgad Shaneh
bdc2b4b59f Remove hard-coded disabling of debug logs
Instead, set the default level of all logs to QtWarningMsg.

The call to setFilterRules overrides the user preferences in qtlogging.ini.

Change-Id: Id5f6cd550d14ff7f45ae04c5d3110e0bafb0f072
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2018-10-13 16:36:58 +00:00
Ivan Donchevskii
e99d09f846 Clang: Properly apply fix-its from header files
Diagnostic may also include fix-its for the header
which require different handling.

Task-number: QTCREATORBUG-20517
Change-Id: I3e745622801be3fa2856d968b0c7a2a2aeb89b50
Reviewed-by: David Schulz <david.schulz@qt.io>
2018-06-28 09:11:49 +00:00
Nikolai Kosjar
bae61e08ea ClangTools: Fix applying fixits one by one
If a file had multiple fixits and only a subset was applied, the
remaining fixits in that file were invalidated. Fix this by adjusting
the locations of the not yet applied fixits.

Change-Id: I2c190412e871e9011c4d4a62ed938e76ad4cdf72
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-05-28 13:54:54 +00:00