4

I used to include tag in my questions about Qt. But after this edit I didn't include it anymore.

I am not Qt developer - that's what I don't ask very much Qt questions.

But I am suspicious that we need tag when asking Qt questions for code highlight.

Randomly I will take this question (I added the tag here) as an example:

It doesn't contain tag

So, what alternatives do we have for syntax-highlight when not using tag but using ?


Update: Even we can set highlighting using language ... it would be better to add highlighting for tag. Turning my question in a feature request.

6
  • Might be worth adding the C++ language hint to the qt tag if they tend to be considered seperate languages (but with highly similar syntax) – Richard Tingle Jan 16 '14 at 12:08
  • 4
    The developers can turn on syntax highlighting for this tag, as shown here, so you could change this question to a feature-request. – Stijn Jan 16 '14 at 12:09
  • Not a dupe, @Stijn has the right answer. – Lance Roberts Jan 16 '14 at 15:24
  • 2
    Note that the tag is also used on Python questions, where defaulting to c++ highlighting would no doubt annoy people. – Wooble Jan 16 '14 at 16:12
  • 1
    @Wooble FWIW, the Python tag does have it's highlighting set to lang-py, so since it's a far more used tag, its own highlighting would still override the Qt tag setting. – animuson ModStaff Jan 16 '14 at 16:40
  • 1
    @animuson: sure, but if C++ people using [qt] don't need to tag [c++], why should Python people use a [python] tag with the [qt] tag? (I guess the broader question is why you wouldn't want to use a language tag all the time if you're asking about a specific language). – Wooble Jan 16 '14 at 16:52
7

If you don't want to use , you can always do this:

<!-- language: lang-cpp -->

    #include <QtGui/QGuiApplication>
    #include "qtquick2applicationviewer.h"
    #include <QQmlContext>
2
  • Note there are other tags with this issue eg c++-amp – Kate Gregory Jan 16 '14 at 13:38
  • I transformed my question in a feature request. – Ionică Bizău Jan 16 '14 at 16:06

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .