updated vym.pro to respect INSTALLDIR qt4-port
authorinsilmaril
Tue Aug 01 09:31:22 2006 +0000 (2006-08-01)
branchqt4-port
changeset 1258e7594239df
parent 11 b8c547f0fc58
child 13 9aadd0f58300
updated vym.pro to respect INSTALLDIR
demos/todo.vym
mainwindow.cpp
mainwindow.h
styles/vym2kdebookmarks.xsl
vym.pro
     1.1 Binary file demos/todo.vym has changed
     2.1 --- a/mainwindow.cpp	Thu Jul 27 14:07:11 2006 +0000
     2.2 +++ b/mainwindow.cpp	Tue Aug 01 09:31:22 2006 +0000
     2.3 @@ -234,6 +234,15 @@
     2.4  
     2.5      statusBar();
     2.6  
     2.7 +	// Position toolbars
     2.8 +	settings.beginGroup("/vym/mainwindow/toolbars/standardFlags");
     2.9 +	TB_standardFlags->move(settings.value("pos").toPoint());
    2.10 +	cout << "moving TB to pos="<<settings.value("pos").toPoint()<<endl;
    2.11 +// FIXME proceed here...	
    2.12 +//	TB_standardFlags->setOrientation(settings.value("orientation").toInt());
    2.13 +//	TB_standardFlags->setVisible(settings.value<QVariant::Bool>("visible",true));
    2.14 +	settings.endGroup();
    2.15 +
    2.16  
    2.17  	// Initialize Find window
    2.18  	findWindow=new FindWindow(NULL,"findwindow");
    2.19 @@ -256,6 +265,14 @@
    2.20  	settings.writeEntry( "/vym/mainwindow/geometry/posX", pos().x() );
    2.21  	settings.writeEntry( "/vym/mainwindow/geometry/posY", pos().y() );
    2.22  
    2.23 +	settings.beginGroup ("/vym/mainwindow/toolbar/standardFlags");
    2.24 +	settings.setValue ("pos",TB_standardFlags->pos());
    2.25 +	settings.setValue ("visible",TB_standardFlags->isVisible());
    2.26 +	settings.setValue ("orientation",TB_standardFlags->orientation());
    2.27 +	settings.endGroup();
    2.28 +
    2.29 +	settings.writeEntry( "/vym/mainwindow/toobar/posY", pos().y() );
    2.30 +
    2.31  	settings.writeEntry( "/vym/version/version", __VYM_VERSION );
    2.32  	settings.writeEntry( "/vym/version/builddate", __BUILD_DATE );
    2.33  
    2.34 @@ -1107,6 +1124,7 @@
    2.35  
    2.36  	// Create Standard Flags
    2.37  	QToolBar *tb=addToolBar (tr ("Standard Flags","Standard Flag Toolbar"));
    2.38 +	TB_standardFlags=tb;
    2.39  
    2.40  	standardFlagsDefault = new FlagRowObj ();
    2.41  	standardFlagsDefault->setVisibility (false);
    2.42 @@ -3056,7 +3074,8 @@
    2.43  
    2.44  void Main::testFunction()
    2.45  {
    2.46 -	currentMapEditor()->testFunction();
    2.47 +	cout <<TB_standardFlags->pos()<<endl;
    2.48 +	//currentMapEditor()->testFunction();
    2.49  }
    2.50  
    2.51  void Main::helpDoc()
     3.1 --- a/mainwindow.h	Thu Jul 27 14:07:11 2006 +0000
     3.2 +++ b/mainwindow.h	Tue Aug 01 09:31:22 2006 +0000
     3.3 @@ -2,12 +2,13 @@
     3.4  #define MAINWINDOW_H
     3.5  
     3.6  #include <q3popupmenu.h>
     3.7 -#include <QMainWindow>
     3.8  #include <q3textedit.h>
     3.9  #include <q3intdict.h>
    3.10  #include <q3canvas.h>
    3.11  #include <qlineedit.h>
    3.12  #include <QAction>
    3.13 +#include <QMainWindow>
    3.14 +#include <QToolBar>
    3.15  #include <qcursor.h>
    3.16  #include <qtabwidget.h>
    3.17  #include <qmap.h>
    3.18 @@ -183,7 +184,7 @@
    3.19      void helpAboutQT();
    3.20  
    3.21  private:
    3.22 -// not needed?    QCanvas* canvas;
    3.23 +	QToolBar *TB_standardFlags;
    3.24  	QTabWidget *tabWidget;
    3.25  	FindWindow *findWindow;
    3.26  	QStringList lastMaps;
     4.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.2 +++ b/styles/vym2kdebookmarks.xsl	Tue Aug 01 09:31:22 2006 +0000
     4.3 @@ -0,0 +1,133 @@
     4.4 +<?xml version="1.0" encoding="UTF-8"?>
     4.5 +<!DOCTYPE xsl:stylesheet
     4.6 +[
     4.7 +   <!-- Namespace for XHTML -->
     4.8 +   <!ENTITY xhtmlns "http://www.w3.org/1999/xhtml">
     4.9 +]>
    4.10 +
    4.11 +<!--
    4.12 +    Author      : Uwe Drechsel  <vym@InSilmaril.de>
    4.13 +	Credits to  : Thomas Schraitle for his patience in explaining XSL to me
    4.14 +    Description : transforms vym maps into KDE Bookmarks
    4.15 +-->
    4.16 +
    4.17 +<xsl:stylesheet version="1.0"
    4.18 +    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    4.19 +    xmlns:date="http://exslt.org/dates-and-times"
    4.20 +    extension-element-prefixes="date">
    4.21 +
    4.22 +
    4.23 +<xsl:output method="xml"
    4.24 +    doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
    4.25 +    doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"
    4.26 +    encoding="UTF-8"
    4.27 +    indent="yes"
    4.28 +    media-type="application/xhtml+xml"/>
    4.29 +
    4.30 +<!-- ======================================= -->
    4.31 +
    4.32 +<xsl:template match="/">
    4.33 +  <xsl:apply-templates/>
    4.34 +</xsl:template>
    4.35 +
    4.36 +
    4.37 +<xsl:template match="text()"/>
    4.38 +
    4.39 +
    4.40 +<xsl:template match="vymmap">
    4.41 +  <xbel>
    4.42 +    <xsl:apply-templates/>
    4.43 +  </xbel>
    4.44 +</xsl:template>
    4.45 +
    4.46 +
    4.47 +<xsl:template match="mapcenter">
    4.48 +
    4.49 +  <xsl:apply-templates/>
    4.50 +</xsl:template>
    4.51 +
    4.52 +
    4.53 +<xsl:template match="branch">
    4.54 +   <xsl:choose>
    4.55 +     <xsl:when test="heading='KDE'">
    4.56 +        <xsl:apply-templates select="branch" mode="kde"/>
    4.57 +     </xsl:when>
    4.58 +     <xsl:when test=". = 'Firefox'">
    4.59 +        <xsl:apply-templates mode="firefox"/>
    4.60 +     </xsl:when>
    4.61 +     <!-- ... -->
    4.62 +     <xsl:otherwise>
    4.63 +       <xsl:apply-templates/>
    4.64 +     </xsl:otherwise>
    4.65 +   </xsl:choose>
    4.66 +
    4.67 +  <xsl:apply-templates/>
    4.68 +</xsl:template>
    4.69 +
    4.70 +<xsl:template match="heading" mode="kde">
    4.71 +      <title>		
    4.72 +      <xsl:value-of select="normalize-space (.)"/>
    4.73 +	  </title>
    4.74 +
    4.75 +   <xsl:choose>
    4.76 +     <xsl:when test=". = 'KDE'">
    4.77 +        <xsl:apply-templates mode="kde"/>
    4.78 +     </xsl:when>
    4.79 +     <xsl:otherwise>
    4.80 +       <xsl:apply-templates/>
    4.81 +     </xsl:otherwise>
    4.82 +   </xsl:choose>
    4.83 +
    4.84 +  <xsl:apply-templates/>
    4.85 +</xsl:template>
    4.86 +
    4.87 +
    4.88 +<xsl:template match="branch" mode="kde">
    4.89 +	<xsl:choose>
    4.90 +		<xsl:when test="@url">
    4.91 +			<xsl:element name="bookmark">	
    4.92 +				<xsl:attribute name="href" ><xsl:value-of select="@url" />
    4.93 +				</xsl:attribute>
    4.94 +				<xsl:apply-templates mode="kde"/>
    4.95 +			</xsl:element>
    4.96 +		</xsl:when>
    4.97 +		<xsl:otherwise>
    4.98 +			<xsl:choose>
    4.99 +				<xsl:when test="contains(heading,'***')">
   4.100 +					<separator folded="yes" />
   4.101 +				</xsl:when>
   4.102 +				<xsl:otherwise>
   4.103 +					<folder folded="yes" icon="bookmark_folder">
   4.104 +						<xsl:apply-templates mode="kde"/>
   4.105 +					</folder>
   4.106 +				</xsl:otherwise>
   4.107 +			</xsl:choose>	
   4.108 +
   4.109 +	</xsl:otherwise>
   4.110 +	</xsl:choose>
   4.111 +</xsl:template>
   4.112 +
   4.113 +<!--
   4.114 +		  <xsl:text>&#10;</xsl:text>
   4.115 +
   4.116 +				<xsl:message> WARNING: No @url attribute given of "<xsl:value-of select="normalize-space(heading)"/>"</xsl:message>
   4.117 +
   4.118 +<xsl:template match="branch">
   4.119 +  <xsl:choose>
   4.120 +    <xsl:when test="@url">
   4.121 +      <xsl:text> *nokde* </xsl:text>
   4.122 +      <xsl:value-of select="@url"/>
   4.123 +      <xsl:text>&#10;</xsl:text>
   4.124 +    </xsl:when>
   4.125 +    <xsl:otherwise>
   4.126 +      <xsl:message> WARNING: No @url attribute given of "<xsl:value-of select="normalize-space(heading)"/>"</xsl:message>
   4.127 +    </xsl:otherwise>
   4.128 +  </xsl:choose>
   4.129 +
   4.130 +  <xsl:apply-templates/>
   4.131 +
   4.132 +</xsl:template>
   4.133 +-->
   4.134 +
   4.135 +
   4.136 +</xsl:stylesheet>
     5.1 --- a/vym.pro	Thu Jul 27 14:07:11 2006 +0000
     5.2 +++ b/vym.pro	Tue Aug 01 09:31:22 2006 +0000
     5.3 @@ -2,7 +2,6 @@
     5.4  LANGUAGE	= C++
     5.5  
     5.6  CONFIG	+= qt warn_on release
     5.7 -QT += qt3support
     5.8  
     5.9  HEADERS	+= aboutdialog.h \
    5.10  	api.h \
    5.11 @@ -70,8 +69,7 @@
    5.12  	settings.cpp \
    5.13  	options.cpp
    5.14  
    5.15 -#The following line was changed from FORMS to FORMS3 by qt3to4
    5.16 -FORMS3	= exportxhtmldialog.ui \
    5.17 +FORMS	= exportxhtmldialog.ui \
    5.18  	showtextdialog.ui \
    5.19  	extrainfodialog.ui \
    5.20  	editxlinkdialog.ui \
    5.21 @@ -83,27 +81,35 @@
    5.22  TRANSLATIONS += lang/vym_es.ts
    5.23  TRANSLATIONS += lang/vym_it.ts
    5.24  
    5.25 +count( INSTALLDIR, 0 ) {
    5.26 +	INSTALLDIR = /usr/local/bin
    5.27 +}
    5.28  
    5.29 +message( "Installation directory" )
    5.30 +message( $$INSTALLDIR )
    5.31  
    5.32 -DESTROOT = /usr
    5.33  
    5.34 -target.path = $${DESTROOT}/bin
    5.35 +target.path = $$INSTALLDIR
    5.36  INSTALLS += target
    5.37  
    5.38 -support.files = exports/ styles/ scripts/ icons/ flags/ lang/
    5.39 -support.path = $${DESTROOT}/share/vym
    5.40 +
    5.41 +target.path = $${INSTALLDIR}/bin
    5.42 +INSTALLS += target
    5.43 +
    5.44 +support.files = styles/ scripts/ icons/ flags/ lang/
    5.45 +support.path = $${INSTALLDIR}/share/vym
    5.46  INSTALLS += support 
    5.47  
    5.48  doc.files = tex/vym.pdf 
    5.49 -doc.path = $${DESTROOT}/share/doc/packages/vym
    5.50 +doc.path = $${INSTALLDIR}/share/doc/packages/vym
    5.51  INSTALLS += doc
    5.52  
    5.53  demo.files = demos/
    5.54 -demo.path = $${DESTROOT}/share/doc/packages/vym
    5.55 +demo.path = $${INSTALLDIR}/share/doc/packages/vym
    5.56  INSTALLS += demo
    5.57  
    5.58 -#The following line was inserted by qt3to4
    5.59 -QT += xml  
    5.60 -#The following line was inserted by qt3to4
    5.61 -CONFIG += uic3
    5.62 +exports.files = exports/
    5.63 +exports.path =$${INSTALLDIR}/share/vym
    5.64 +INSTALLS += exports
    5.65  
    5.66 +