summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleks Kissinger <aleks0@gmail.com>2018-10-20 10:59:37 +0200
committerAleks Kissinger <aleks0@gmail.com>2018-10-20 10:59:37 +0200
commit56b21f3107fb36edeed15544a30238e4f57b977c (patch)
tree85ce810e29413f1835bf2ce76cce2218e070bf98
parent092c5c6b84b92a40e210ee7447fc7dbd3b492ca4 (diff)
added mac target for qt 5.6
-rw-r--r--.travis.yml32
-rw-r--r--src/gui/mainwindow.cpp6
-rw-r--r--src/gui/mainwindow.ui3
-rw-r--r--tikzit.pro7
-rw-r--r--tikzlexer.h257
5 files changed, 209 insertions, 96 deletions
diff --git a/.travis.yml b/.travis.yml
index 91e7272..98be8d2 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -9,21 +9,33 @@ matrix:
compiler: clang
env:
- FILE=tikzit-osx.dmg
- - os: linux
- dist: trusty
+ - QTVER=511
+ - os: osx
+ compiler: clang
env:
- - FILE=tikzit-linux.tar.gz
- - PPA=beineri/opt-qt-5.10.1-trusty
+ - FILE=tikzit-osx-mountain.dmg
+ - QTVER=56
+ # - os: linux
+ # dist: trusty
+ # env:
+ # - FILE=tikzit-linux.tar.gz
+ # - PPA=beineri/opt-qt-5.10.1-trusty
before_install:
- - '[[ "$TRAVIS_OS_NAME" != linux || -z "$PPA" ]] || sudo add-apt-repository -y ppa:$PPA'
- - '[[ "$TRAVIS_OS_NAME" != linux ]] || sudo apt-get -qy update'
+ # - '[[ "$TRAVIS_OS_NAME" != linux || -z "$PPA" ]] || sudo add-apt-repository -y ppa:$PPA'
+ # - '[[ "$TRAVIS_OS_NAME" != linux ]] || sudo apt-get -qy update'
+ - '[[ "$TRAVIS_OS_NAME" != osx || "$QTVER" != 56 ]] || curl https://raw.githubusercontent.com/GiovanniBussi/macports-ci/master/macports-ci > macports-ci'
+ - '[[ "$TRAVIS_OS_NAME" != osx || "$QTVER" != 56 ]] || source macports-ci install'
+
+
install:
- - '[[ "$TRAVIS_OS_NAME" != osx ]] || brew install qt5'
- - '[[ "$TRAVIS_OS_NAME" != osx ]] || brew link --force qt5'
- - '[[ "$TRAVIS_OS_NAME" != linux ]] || sudo apt-get -qy install qt510base qt510xmlpatterns'
- - '[[ "$TRAVIS_OS_NAME" != linux ]] || . /opt/qt510/bin/qt510-env.sh'
+ - '[[ "$TRAVIS_OS_NAME" != osx || "$QTVER" != 511 ]] || brew install qt5'
+ - '[[ "$TRAVIS_OS_NAME" != osx || "$QTVER" != 511 ]] || brew link --force qt5'
+ - '[[ "$TRAVIS_OS_NAME" != osx || "$QTVER" != 56 ]] || sudo port -N -k install qt56'
+ - '[[ "$TRAVIS_OS_NAME" != osx || "$QTVER" != 56 ]] || export PATH=/opt/local/libexec/qt5/bin:$PATH'
+ # - '[[ "$TRAVIS_OS_NAME" != linux ]] || sudo apt-get -qy install qt510base qt510xmlpatterns'
+ # - '[[ "$TRAVIS_OS_NAME" != linux ]] || . /opt/qt510/bin/qt510-env.sh'
script:
- qmake -v
diff --git a/src/gui/mainwindow.cpp b/src/gui/mainwindow.cpp
index acbad69..d4d13b5 100644
--- a/src/gui/mainwindow.cpp
+++ b/src/gui/mainwindow.cpp
@@ -70,6 +70,12 @@ MainWindow::MainWindow(QWidget *parent) :
connect(_tikzDocument->undoStack(), SIGNAL(cleanChanged(bool)), this, SLOT(updateFileName()));
_menu->addDocks(createPopupMenu());
+
+#if (QT_VERSION >= QT_VERSION_CHECK(5, 10, 0))
+ ui->tikzSource->setTabStopDistance(20.0);
+#else
+ ui->tikzSource->setTabStopWidth(20);
+#endif
}
MainWindow::~MainWindow()
diff --git a/src/gui/mainwindow.ui b/src/gui/mainwindow.ui
index 27e0127..bedc695 100644
--- a/src/gui/mainwindow.ui
+++ b/src/gui/mainwindow.ui
@@ -62,9 +62,6 @@ p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Courier New'; font-size:10pt; font-weight:400; font-style:normal;&quot;&gt;
&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'.SF NS Text'; font-size:13pt;&quot;&gt;&lt;br /&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
- <property name="tabStopDistance">
- <double>20.000000000000000</double>
- </property>
</widget>
</widget>
</item>
diff --git a/tikzit.pro b/tikzit.pro
index c0d8729..c4b8f84 100644
--- a/tikzit.pro
+++ b/tikzit.pro
@@ -31,9 +31,10 @@ win32:RC_ICONS += images/tikzdoc.ico
macx:ICON = images/tikzit.icns
# linux-g++:QMAKE_CXXFLAGS += -Wsuggest-override
-#!versionAtLeast(QT_VERSION, 5.7.0) {
-# macx:QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.8
-#}
+# Qt 5.8 and above drop support for Mountain Lion
+contains(QT_VERSION, ^5\\.[5-7].*) {
+ macx:QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.8
+}
# The following define makes your compiler emit warnings if you use
# any feature of Qt which as been marked as deprecated (the exact warnings
diff --git a/tikzlexer.h b/tikzlexer.h
index 5f18d12..438947f 100644
--- a/tikzlexer.h
+++ b/tikzlexer.h
@@ -2,9 +2,9 @@
#define yyHEADER_H 1
#define yyIN_HEADER 1
-#line 5 "tikzlexer.h"
+#line 6 "tikzlexer.h"
-#line 7 "tikzlexer.h"
+#line 8 "tikzlexer.h"
#define YY_INT_ALIGNED short int
@@ -13,88 +13,34 @@
#define FLEX_SCANNER
#define YY_FLEX_MAJOR_VERSION 2
#define YY_FLEX_MINOR_VERSION 6
-#define YY_FLEX_SUBMINOR_VERSION 3
+#define YY_FLEX_SUBMINOR_VERSION 4
#if YY_FLEX_SUBMINOR_VERSION > 0
#define FLEX_BETA
#endif
- #define yy_create_buffer yy_create_buffer
-
- #define yy_delete_buffer yy_delete_buffer
-
- #define yy_scan_buffer yy_scan_buffer
-
- #define yy_scan_string yy_scan_string
-
- #define yy_scan_bytes yy_scan_bytes
-
- #define yy_init_buffer yy_init_buffer
-
- #define yy_flush_buffer yy_flush_buffer
-
- #define yy_load_buffer_state yy_load_buffer_state
-
- #define yy_switch_to_buffer yy_switch_to_buffer
-
- #define yypush_buffer_state yypush_buffer_state
-
- #define yypop_buffer_state yypop_buffer_state
-
- #define yyensure_buffer_stack yyensure_buffer_stack
-
- #define yylex yylex
-
- #define yyrestart yyrestart
-
- #define yylex_init yylex_init
-
- #define yylex_init_extra yylex_init_extra
-
- #define yylex_destroy yylex_destroy
-
- #define yyget_debug yyget_debug
-
- #define yyset_debug yyset_debug
-
- #define yyget_extra yyget_extra
-
- #define yyset_extra yyset_extra
-
- #define yyget_in yyget_in
-
- #define yyset_in yyset_in
-
- #define yyget_out yyget_out
-
- #define yyset_out yyset_out
-
- #define yyget_leng yyget_leng
-
- #define yyget_text yyget_text
-
- #define yyget_lineno yyget_lineno
-
- #define yyset_lineno yyset_lineno
-
- #define yyget_column yyget_column
-
- #define yyset_column yyset_column
-
- #define yywrap yywrap
-
- #define yyget_lval yyget_lval
-
- #define yyset_lval yyset_lval
-
- #define yyget_lloc yyget_lloc
-
- #define yyset_lloc yyset_lloc
+#ifdef yyget_lval
+#define yyget_lval_ALREADY_DEFINED
+#else
+#define yyget_lval yyget_lval
+#endif
- #define yyalloc yyalloc
+#ifdef yyset_lval
+#define yyset_lval_ALREADY_DEFINED
+#else
+#define yyset_lval yyset_lval
+#endif
- #define yyrealloc yyrealloc
+#ifdef yyget_lloc
+#define yyget_lloc_ALREADY_DEFINED
+#else
+#define yyget_lloc yyget_lloc
+#endif
- #define yyfree yyfree
+#ifdef yyset_lloc
+#define yyset_lloc_ALREADY_DEFINED
+#else
+#define yyset_lloc yyset_lloc
+#endif
/* First, we deal with platform-specific or compiler-specific issues. */
@@ -166,10 +112,16 @@ typedef unsigned int flex_uint32_t;
#define UINT32_MAX (4294967295U)
#endif
+#ifndef SIZE_MAX
+#define SIZE_MAX (~(size_t)0)
+#endif
+
#endif /* ! C99 */
#endif /* ! FLEXINT_H */
+/* begin standard C++ headers. */
+
/* TODO: this is always defined, so inline it */
#define yyconst const
@@ -307,7 +259,7 @@ void yyfree ( void * , yyscan_t yyscanner );
*/
#include <unistd.h>
#endif
-
+
#define YY_EXTRA_TYPE TikzAssembler *
int yylex_init (yyscan_t* scanner);
@@ -421,8 +373,153 @@ extern int yylex \
#undef YY_DECL
#endif
-#line 195 "src\\data\\tikzlexer.l"
+#ifndef yy_create_buffer_ALREADY_DEFINED
+#undef yy_create_buffer
+#endif
+#ifndef yy_delete_buffer_ALREADY_DEFINED
+#undef yy_delete_buffer
+#endif
+#ifndef yy_scan_buffer_ALREADY_DEFINED
+#undef yy_scan_buffer
+#endif
+#ifndef yy_scan_string_ALREADY_DEFINED
+#undef yy_scan_string
+#endif
+#ifndef yy_scan_bytes_ALREADY_DEFINED
+#undef yy_scan_bytes
+#endif
+#ifndef yy_init_buffer_ALREADY_DEFINED
+#undef yy_init_buffer
+#endif
+#ifndef yy_flush_buffer_ALREADY_DEFINED
+#undef yy_flush_buffer
+#endif
+#ifndef yy_load_buffer_state_ALREADY_DEFINED
+#undef yy_load_buffer_state
+#endif
+#ifndef yy_switch_to_buffer_ALREADY_DEFINED
+#undef yy_switch_to_buffer
+#endif
+#ifndef yypush_buffer_state_ALREADY_DEFINED
+#undef yypush_buffer_state
+#endif
+#ifndef yypop_buffer_state_ALREADY_DEFINED
+#undef yypop_buffer_state
+#endif
+#ifndef yyensure_buffer_stack_ALREADY_DEFINED
+#undef yyensure_buffer_stack
+#endif
+#ifndef yylex_ALREADY_DEFINED
+#undef yylex
+#endif
+#ifndef yyrestart_ALREADY_DEFINED
+#undef yyrestart
+#endif
+#ifndef yylex_init_ALREADY_DEFINED
+#undef yylex_init
+#endif
+#ifndef yylex_init_extra_ALREADY_DEFINED
+#undef yylex_init_extra
+#endif
+#ifndef yylex_destroy_ALREADY_DEFINED
+#undef yylex_destroy
+#endif
+#ifndef yyget_debug_ALREADY_DEFINED
+#undef yyget_debug
+#endif
+#ifndef yyset_debug_ALREADY_DEFINED
+#undef yyset_debug
+#endif
+#ifndef yyget_extra_ALREADY_DEFINED
+#undef yyget_extra
+#endif
+#ifndef yyset_extra_ALREADY_DEFINED
+#undef yyset_extra
+#endif
+#ifndef yyget_in_ALREADY_DEFINED
+#undef yyget_in
+#endif
+#ifndef yyset_in_ALREADY_DEFINED
+#undef yyset_in
+#endif
+#ifndef yyget_out_ALREADY_DEFINED
+#undef yyget_out
+#endif
+#ifndef yyset_out_ALREADY_DEFINED
+#undef yyset_out
+#endif
+#ifndef yyget_leng_ALREADY_DEFINED
+#undef yyget_leng
+#endif
+#ifndef yyget_text_ALREADY_DEFINED
+#undef yyget_text
+#endif
+#ifndef yyget_lineno_ALREADY_DEFINED
+#undef yyget_lineno
+#endif
+#ifndef yyset_lineno_ALREADY_DEFINED
+#undef yyset_lineno
+#endif
+#ifndef yyget_column_ALREADY_DEFINED
+#undef yyget_column
+#endif
+#ifndef yyset_column_ALREADY_DEFINED
+#undef yyset_column
+#endif
+#ifndef yywrap_ALREADY_DEFINED
+#undef yywrap
+#endif
+#ifndef yyget_lval_ALREADY_DEFINED
+#undef yyget_lval
+#endif
+#ifndef yyset_lval_ALREADY_DEFINED
+#undef yyset_lval
+#endif
+#ifndef yyget_lloc_ALREADY_DEFINED
+#undef yyget_lloc
+#endif
+#ifndef yyset_lloc_ALREADY_DEFINED
+#undef yyset_lloc
+#endif
+#ifndef yyalloc_ALREADY_DEFINED
+#undef yyalloc
+#endif
+#ifndef yyrealloc_ALREADY_DEFINED
+#undef yyrealloc
+#endif
+#ifndef yyfree_ALREADY_DEFINED
+#undef yyfree
+#endif
+#ifndef yytext_ALREADY_DEFINED
+#undef yytext
+#endif
+#ifndef yyleng_ALREADY_DEFINED
+#undef yyleng
+#endif
+#ifndef yyin_ALREADY_DEFINED
+#undef yyin
+#endif
+#ifndef yyout_ALREADY_DEFINED
+#undef yyout
+#endif
+#ifndef yy_flex_debug_ALREADY_DEFINED
+#undef yy_flex_debug
+#endif
+#ifndef yylineno_ALREADY_DEFINED
+#undef yylineno
+#endif
+#ifndef yytables_fload_ALREADY_DEFINED
+#undef yytables_fload
+#endif
+#ifndef yytables_destroy_ALREADY_DEFINED
+#undef yytables_destroy
+#endif
+#ifndef yyTABLES_NAME_ALREADY_DEFINED
+#undef yyTABLES_NAME
+#endif
+
+#line 195 "src/data/tikzlexer.l"
-#line 426 "tikzlexer.h"
+#line 524 "tikzlexer.h"
#undef yyIN_HEADER
#endif /* yyHEADER_H */