mirror of
https://github.com/KevinMidboe/linguist.git
synced 2025-10-29 17:50:22 +00:00
Adding QMake (Make-like) language.
Mostly because the file extension conflicts with that of Prolog.
This commit is contained in:
@@ -1296,6 +1296,12 @@ QML:
|
|||||||
color: "#44a51c"
|
color: "#44a51c"
|
||||||
primary_extension: .qml
|
primary_extension: .qml
|
||||||
|
|
||||||
|
QMake:
|
||||||
|
primary_extension: .pro
|
||||||
|
lexer: Text only
|
||||||
|
extensions:
|
||||||
|
- .pri
|
||||||
|
|
||||||
R:
|
R:
|
||||||
type: programming
|
type: programming
|
||||||
color: "#198ce7"
|
color: "#198ce7"
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
30
samples/QMake/complex.pro
Normal file
30
samples/QMake/complex.pro
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
# This QMake file is complex, as it usese
|
||||||
|
# boolean operators and function calls
|
||||||
|
|
||||||
|
QT += core gui
|
||||||
|
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
|
||||||
|
|
||||||
|
# We could use some OpenGL right now
|
||||||
|
contains(QT_CONFIG, opengl) | contains(QT_CONFIG, opengles2) {
|
||||||
|
QT += opengl
|
||||||
|
} else {
|
||||||
|
DEFINES += QT_NO_OPENGL
|
||||||
|
}
|
||||||
|
|
||||||
|
TEMPLATE = app
|
||||||
|
win32 {
|
||||||
|
TARGET = BlahApp
|
||||||
|
RC_FILE = Resources/winres.rc
|
||||||
|
}
|
||||||
|
!win32 { TARGET = blahapp }
|
||||||
|
|
||||||
|
# Let's add a PRI file!
|
||||||
|
include(functions.pri)
|
||||||
|
|
||||||
|
SOURCES += file.cpp
|
||||||
|
|
||||||
|
HEADERS += file.h
|
||||||
|
|
||||||
|
FORMS += file.ui
|
||||||
|
|
||||||
|
RESOURCES += res.qrc
|
||||||
8
samples/QMake/functions.pri
Normal file
8
samples/QMake/functions.pri
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
# QMake include file that calls some functions
|
||||||
|
# and does nothing else...
|
||||||
|
|
||||||
|
exists(.git/HEAD) {
|
||||||
|
system(git rev-parse HEAD >rev.txt)
|
||||||
|
} else {
|
||||||
|
system(echo ThisIsNotAGitRepo >rev.txt)
|
||||||
|
}
|
||||||
2
samples/QMake/qmake.script!
Normal file
2
samples/QMake/qmake.script!
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
#!/usr/bin/qmake
|
||||||
|
message(This is QMake.)
|
||||||
17
samples/QMake/simple.pro
Normal file
17
samples/QMake/simple.pro
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
# Simple QMake file
|
||||||
|
|
||||||
|
CONFIG += qt
|
||||||
|
QT += core gui
|
||||||
|
TEMPLATE = app
|
||||||
|
TARGET = simpleapp
|
||||||
|
|
||||||
|
SOURCES += file.cpp \
|
||||||
|
file2.c \
|
||||||
|
This/Is/Folder/file3.cpp
|
||||||
|
|
||||||
|
HEADERS += file.h \
|
||||||
|
file2.h \
|
||||||
|
This/Is/Folder/file3.h
|
||||||
|
|
||||||
|
FORMS += This/Is/Folder/file3.ui \
|
||||||
|
Test.ui
|
||||||
Reference in New Issue
Block a user