Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
merge from trunk r11150:11200
git-svn-id: http://svn.osgeo.org/qgis/branches/symbology-ng-branch@11883 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
wonder committed Nov 2, 2009
1 parent 92cf64d commit bbaf61d
Show file tree
Hide file tree
Showing 91 changed files with 2,634 additions and 1,834 deletions.
32 changes: 12 additions & 20 deletions CMakeLists.txt
Expand Up @@ -201,9 +201,10 @@ IF (PEDANTIC)
ENDIF (MSVC)
ENDIF (PEDANTIC)

IF (CMAKE_BUILD_TYPE MATCHES Debug)
IF (CMAKE_BUILD_TYPE MATCHES Debug OR CMAKE_CONFIGURATION_TYPE MATCHES RelWithDebInfo)
MESSAGE ("-- Debug output enabled")
ADD_DEFINITIONS(-DQGISDEBUG=1)
ENDIF (CMAKE_BUILD_TYPE MATCHES Debug)
ENDIF (CMAKE_BUILD_TYPE MATCHES Debug OR CMAKE_CONFIGURATION_TYPE MATCHES RelWithDebInfo)

#############################################################
# platform specific stuff
Expand All @@ -215,18 +216,10 @@ IF (WIN32)
SET (DEFAULT_INCLUDE_SUBDIR include)

IF (MSVC)
# Python parts need to be build with nmake not vcexpress
# if you dont add this clause, extra blank msvc projects
# will pop up mid way through the build process and block
# the build, plus the python bindings wont build correctly
SET (CMAKE_MAKE_PROGRAM nmake)
SET (DEFAULT_BIN_SUBDIR bin)
# put all the build products into a single directory
# under build (doesnt affect install target) to make for
# easier debugging.
# SET(OUTPUT_DIR ${CMAKE_CURRENT_SOURCE_DIR}/bin)
# SET(EXECUTABLE_OUTPUT_PATH ${OUTPUT_DIR})
# SET(LIBRARY_OUTPUT_PATH ${OUTPUT_DIR})
#tell msvc compiler to use main instead of winmain as the
#application entry point
#SET(QT_USE_QTMAIN TRUE)
Expand All @@ -236,18 +229,17 @@ IF (WIN32)
# Turn off deprecation warnings
ADD_DEFINITIONS(-D_CRT_SECURE_NO_WARNINGS)
ADD_DEFINITIONS(-D_CRT_NONSTDC_NO_WARNINGS)
# Some file access stuff not defined in native win32
# environment
ADD_DEFINITIONS(-DF_OK=0)
ADD_DEFINITIONS(-DX_OK=1)
ADD_DEFINITIONS(-DW_OK=2)
ADD_DEFINITIONS(-DR_OK=4)

ADD_DEFINITIONS(-DQGISDEBUG=1)

INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/win_build/vcdeps/. DESTINATION .)
IF (CMAKE_BUILD_TYPE MATCHES Debug OR CMAKE_CONFIGURATION_TYPE MATCHES RelWithDebInfo)
MESSAGE ("-- Generating browse files")
ADD_DEFINITIONS( /FR )
ENDIF (CMAKE_BUILD_TYPE MATCHES Debug OR CMAKE_CONFIGURATION_TYPE MATCHES RelWithDebInfo)

IF (INSTALL_DEPS)
INSTALL(DIRECTORY ${INSTALL_DEPS} DESTINATION .)
ENDIF (INSTALL_DEPS)
ELSE(MSVC)
SET (DEFAULT_BIN_SUBDIR .)
SET (DEFAULT_BIN_SUBDIR .)
ENDIF(MSVC)
ELSE (WIN32)

Expand Down
2 changes: 1 addition & 1 deletion cmake/FindGRASS.cmake
Expand Up @@ -11,7 +11,7 @@ MACRO (CHECK_GRASS G_PREFIX)

FOREACH (LIB ${GRASS_LIB_NAMES})
SET(LIB_PATH NOTFOUND)
FIND_LIBRARY(LIB_PATH grass_${LIB} PATHS ${G_PREFIX}/lib)
FIND_LIBRARY(LIB_PATH NAMES grass_${LIB} PATHS ${G_PREFIX}/lib NO_DEFAULT_PATH)

IF (LIB_PATH)
IF (NOT GRASS_LIBRARIES STREQUAL NOTFOUND)
Expand Down
1,245 changes: 754 additions & 491 deletions i18n/qgis_de.ts

Large diffs are not rendered by default.

Binary file added images/themes/classic/mActionSaveAsPDF.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/themes/gis/mActionSaveAsPDF.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
73 changes: 47 additions & 26 deletions mac/xcode/Qgis.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

127 changes: 127 additions & 0 deletions ms-windows/osgeo4w/package.cmd
@@ -0,0 +1,127 @@
@echo off
set GRASS_VERSION=6.4.0svn

path %SYSTEMROOT%\system32;%SYSTEMROOT%;%SYSTEMROOT%\System32\Wbem;%PROGRAMFILES%\CMake 2.6\bin
set PYTHONPATH=

set VS90COMNTOOLS=%PROGRAMFILES%\Microsoft Visual Studio 9.0\Common7\Tools\
call "%PROGRAMFILES%\Microsoft Visual Studio 9.0\VC\vcvarsall.bat" x86

set OSGEO4W_ROOT=%PROGRAMFILES%\OSGeo4W
call "%OSGEO4W_ROOT%\bin\o4w_env.bat"

set LIB_DIR=%OSGEO4W_ROOT%

set FLEX=%PROGRAMFILES%\GnuWin32\bin\flex.exe
set BISON=%PROGRAMFILES%\GnuWin32\bin\bison.exe

set VERSION=%1
set PACKAGE=%2

PROMPT qgis%VERSION%$g

set BUILDCONF=RelWithDebInfo
REM set BUILDCONF=Release

if not exist build mkdir build
if not exist build goto error

if not exist build.log goto build

REM
REM try renaming the logfile to see if it's locked
REM

if exist build.tmp del build.tmp
if exist build.tmp goto error

ren build.log build.tmp
if exist build.log goto locked
if not exist build.tmp goto locked

ren build.tmp build.log
if exist build.tmp goto locked
if not exist build.log goto locked

goto build

:locked
echo Logfile locked
if exist build.tmp del build.tmp
goto error

:build
set LOG=%CD%\build.log

cd build

echo Logging to %LOG%
echo BEGIN: %DATE% %TIME%>>%LOG% 2>&1
if errorlevel 1 goto error

set >buildenv.log

if exist CMakeCache.txt goto skipcmake

echo CMAKE: %DATE% %TIME%>>%LOG% 2>&1
if errorlevel 1 goto error

cmake -G "Visual Studio 9 2008" ^
-D PEDANTIC=TRUE ^
-D WITH_SPATIALITE=TRUE ^
-D WITH_INTERNAL_SPATIALITE=TRUE ^
-D CMAKE_CONFIGURATION_TYPE=%BUILDCONF% ^
-D CMAKE_BUILDCONFIGURATION_TYPES=%BUILDCONF% ^
-D FLEX_EXECUTABLE=%FLEX% ^
-D BISON_EXECUTABLE=%BISON% ^
-D GDAL_INCLUDE_DIR=%OSGEO4W_ROOT%\apps\gdal-16\include -D GDAL_LIBRARY=%OSGEO4W_ROOT%\apps\gdal-16\lib\gdal_i.lib ^
-D PYTHON_EXECUTABLE=%OSGEO4W_ROOT%\bin\python.exe ^
-D PYTHON_INCLUDE_DIR=%OSGEO4W_ROOT%\apps\Python25\include -D PYTHON_LIBRARY=%OSGEO4W_ROOT%\apps\Python25\libs\python25.lib ^
-D SIP_BINARY_PATH=%OSGEO4W_ROOT%\apps\Python25\sip.exe ^
-D GRASS_PREFIX=%OSGEO4W_ROOT%\apps\grass\grass-%GRASS_VERSION% ^
-D QT_BINARY_DIR=%OSGEO4W_ROOT%\bin -D QT_LIBRARY_DIR=%OSGEO4W_ROOT%\lib ^
-D QT_HEADERS_DIR=%OSGEO4W_ROOT%\include\qt4 ^
-D QT_ZLIB_LIBRARY=%OSGEO4W_ROOT%\lib\zlib.lib ^
-D QT_PNG_LIBRARY=%OSGEO4W_ROOT%\lib\libpng13.lib ^
-D CMAKE_INSTALL_PREFIX=%OSGEO4W_ROOT%\apps\qgis-dev ^
../../..>>%LOG% 2>&1
if errorlevel 1 goto error

:skipcmake

echo ZERO_CHECK: %DATE% %TIME%>>%LOG% 2>&1
devenv qgis%VERSION%.sln /Project ZERO_CHECK /Build %BUILDCONF%>>%LOG% 2>&1
if errorlevel 1 goto error

echo ALL_BUILD: %DATE% %TIME%>>%LOG% 2>&1
devenv qgis%VERSION%.sln /Project ALL_BUILD /Build %BUILDCONF%>>%LOG% 2>&1
if errorlevel 1 goto error

echo INSTALL: %DATE% %TIME%>>%LOG% 2>&1
devenv qgis%VERSION%.sln /Project INSTALL /Build %BUILDCONF%>>%LOG% 2>&1
if errorlevel 1 goto error

echo PACKAGE: %DATE% %TIME%>>%LOG% 2>&1

cd ..
copy postinstall.bat %OSGEO4W_ROOT%\etc\postinstall\qgis-dev.bat
copy preremove.bat %OSGEO4W_ROOT%\etc\preremove\qgis-dev.bat
copy qgis-dev.bat.tmpl %OSGEO4W_ROOT%\bin\qgis-dev.bat.tmpl

tar -C %OSGEO4W_ROOT% -cjf qgis-dev-%VERSION%-%PACKAGE%.tar.bz2 ^
--exclude "apps/qgis-dev/plugins/EDBSQuery.dll" ^
apps/qgis-dev ^
bin/qgis-dev.bat.tmpl ^
etc/postinstall/qgis-dev.bat ^
etc/preremove/qgis-dev.bat>>%LOG% 2>&1
if errorlevel 1 goto error

goto end

:error
echo BUILD ERROR %ERRORLEVEL%: %DATE% %TIME%
echo BUILD ERROR %ERRORLEVEL%: %DATE% %TIME%>>%LOG% 2>&1
if exist qgis-dev-%VERSION%-%PACKAGE%.tar.bz2 del qgis-dev-%VERSION%-%PACKAGE%.tar.bz2

:end
echo FINISHED: %DATE% %TIME% >>%LOG% 2>&1
5 changes: 5 additions & 0 deletions ms-windows/osgeo4w/postinstall.bat
@@ -0,0 +1,5 @@
textreplace -std -t bin\qgis-dev.bat

mkdir "%OSGEO4W_STARTMENU%"
xxmklink "%OSGEO4W_STARTMENU%\Quantum GIS (trunk).lnk" "%OSGEO4W_ROOT%\bin\qgis-dev.bat" " " \ "Quantum GIS - Desktop GIS (trunk)" 1 "%OSGEO4W_ROOT%\apps\qgis-dev\icons\QGIS.ico"
xxmklink "%ALLUSERSPROFILE%\Desktop\Quantum GIS (trunk).lnk" "%OSGEO4W_ROOT%\bin\qgis-dev.bat" " " \ "Quantum GIS - Desktop GIS (trunk)" 1 "%OSGEO4W_ROOT%\apps\qgis-dev\icons\QGIS.ico"
3 changes: 3 additions & 0 deletions ms-windows/osgeo4w/preremove.bat
@@ -0,0 +1,3 @@
del "%OSGEO4W_STARTMENU%\Quantum GIS (trunk).lnk"
del "%ALLUSERSPROFILE%\Desktop\Quantum GIS (trunk).lnk"
del "%OSGEO4W_ROOT%\bin\qgis-dev.bat
8 changes: 8 additions & 0 deletions ms-windows/osgeo4w/qgis-dev.bat.tmpl
@@ -0,0 +1,8 @@
@echo off

SET OSGEO4W_ROOT=@osgeo4w@
call "%OSGEO4W_ROOT%"\bin\o4w_env.bat
call "%OSGEO4W_ROOT%"\bin\gdal16.bat
@echo off
path %PATH%;%GISBASE%\bin
start "Quantum GIS" /B "%OSGEO4W_ROOT%"\apps\qgis-dev\bin\qgis.exe %*
1 change: 1 addition & 0 deletions python/CMakeLists.txt
Expand Up @@ -50,6 +50,7 @@ CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/configure.py.in

IF (MSVC)
SET(EXPORT "__declspec(dllimport)")
SET(CMAKE_MAKE_PROGRAM $ENV{VCINSTALLDIR}/bin/nmake.exe)
ELSE (MSVC)
SET(EXPORT "")
ENDIF (MSVC)
Expand Down
5 changes: 3 additions & 2 deletions python/core/qgscontinuouscolorrenderer.sip
Expand Up @@ -10,8 +10,9 @@ class QgsContinuousColorRenderer : QgsRenderer
QgsContinuousColorRenderer(QGis::GeometryType type);
QgsContinuousColorRenderer(const QgsContinuousColorRenderer& other);
virtual ~QgsContinuousColorRenderer();
/**Renders the feature using the minimum and maximum value of the classification field*/
void renderFeature(QPainter* p, QgsFeature& f, QImage* img, bool selected, double widthScale = 1.0, double rasterScaleFactor = 1.0);
/**Renders the feature using the minimum and maximum value of the classification field
* added in 1.2 */
void renderFeature(QgsRenderContext &renderContext, QgsFeature& f, QImage* img, bool selected);
/**Returns the number of the classification field*/
int classificationField() const;
/**Sets the id of the classification field*/
Expand Down
4 changes: 2 additions & 2 deletions python/core/qgsgraduatedsymbolrenderer.sip
Expand Up @@ -48,11 +48,11 @@ class QgsGraduatedSymbolRenderer : QgsRenderer
@param f a pointer to the feature to determine if rendering will happen*/
bool willRenderFeature(QgsFeature *f);

/**Renders an OGRFeature
/**Renders a feature
\param p a painter (usually the one from the current map canvas)
\param f a pointer to a feature to render
\param t the transform object containing the information how to transform the map coordinates to screen coordinates*/
void renderFeature(QPainter* p, QgsFeature& f, QImage* img, bool selected, double widthScale = 1.0, double rasterScaleFactor = 1.0);
void renderFeature(QgsRenderContext &renderContext, QgsFeature& f, QImage* img, bool selected);

/**Sets the number of the classicifation field
\param field the number of the field to classify*/
Expand Down
16 changes: 13 additions & 3 deletions python/core/qgslabel.sip
Expand Up @@ -45,14 +45,24 @@ public:
QgsPoint p;
double angle;
};



/** \brief render label
* \param sizeScale global scale factor for size in pixels, labels in map units are not scaled
*/
\note deprecated
*/
void renderLabel ( QPainter* painter, QgsRectangle& viewExtent,
QgsCoordinateTransform* coordinateTransform,
QgsMapToPixel *transform,
QgsFeature &feature, bool selected, QgsLabelAttributes *classAttributes=0, double sizeScale = 1, double rasterScaleFactor = 1);

/** \brief render label
* \param renderContext renderer context
* \param feature feature to render
* \param selected is to be shown selected
* \param classAttributes attributes to use for labeling
* \note added in 1.2
*/
void renderLabel ( QgsRenderContext &renderContext, QgsFeature &feature, bool selected, QgsLabelAttributes *classAttributes=0);

/** Reads the renderer configuration from an XML file
@param rnode the Dom node to read
Expand Down
12 changes: 11 additions & 1 deletion python/core/qgsmarkercatalogue.sip
@@ -1,6 +1,6 @@

/** Catalogue of point symbols */
class QgsMarkerCatalogue /NoDefaultCtors/
class QgsMarkerCatalogue : QObject /NoDefaultCtors/
{
%TypeHeaderCode
#include <qgsmarkercatalogue.h>
Expand Down Expand Up @@ -29,5 +29,15 @@ public:
/** Returns a pixmap given a file name of a svg marker
* NOTE: this method needs to be public static for QgsMarkerDialog::visualizeMarkers */
static void svgMarker (QPainter * thepPainter, QString name, int size );

public slots:
// reload the symbols
// added in 1.2
void refreshList();

signals:
// symbols were reloaded
// added in 1.2
void markersRefreshed();
};

18 changes: 16 additions & 2 deletions python/core/qgsrenderer.sip
Expand Up @@ -15,8 +15,22 @@ class QgsRenderer
@param p the painter storing brush and pen
@param f a pointer to the feature to be rendered
@param pic pointer to a marker from SVG (is only used by marker renderers)
@param scalefactor pointer to the scale factor for the marker image*/
virtual void renderFeature(QPainter* p, QgsFeature& f,QImage* pic, bool selected, double widthScale = 1.0, double rasterScaleFactor = 1.0)=0;
@param selected feature is to be shown selected
@param widthScale scale factor
@param rasterScaleFactor scale factor for rasters

deprecated */
void renderFeature(QPainter* p, QgsFeature& f,QImage* pic, bool selected, double widthScale = 1.0, double rasterScaleFactor = 1.0);

/**A vector layer passes features to a renderer object to change the brush ans pen of the qpainter
@param renderContext context of the rendering operation
@param f the feature to render
@param pic pointer to marker to render (is only used by marker renderers)
@param selected the feature is to be shown selected

added in 1.2 */
virtual void renderFeature(QgsRenderContext &renderContext, QgsFeature& f,QImage* pic, bool selected)=0;

/**Reads the renderer configuration from an XML file
@param rnode the Dom node to read
@param vl the vector layer which will be associated with the renderer*/
Expand Down
7 changes: 5 additions & 2 deletions python/core/qgssinglesymbolrenderer.sip
Expand Up @@ -9,12 +9,15 @@ class QgsSingleSymbolRenderer : QgsRenderer
QgsSingleSymbolRenderer(QGis::GeometryType type);
QgsSingleSymbolRenderer(const QgsSingleSymbolRenderer& other);
virtual ~QgsSingleSymbolRenderer();

/**Replaces the current mSymbol by sy*/
void addSymbol(QgsSymbol* sy /Transfer/);
/*Returns a pointer to mSymbol*/
const QgsSymbol* symbol() const;
/**Renders an OGRFeature*/
void renderFeature(QPainter* p, QgsFeature& f, QImage* img, bool selected, double widthScale = 1.0, double rasterScaleFactor = 1.0);

/**Renders a feature added in 1.2 */
void renderFeature(QgsRenderContext &renderContext, QgsFeature& f, QImage* img, bool selected);

/**Reads the renderer configuration from an XML file
@param rnode the Dom node to read
@param vl the vector layer which will be associated with the renderer*/
Expand Down
6 changes: 5 additions & 1 deletion python/core/qgsuniquevaluerenderer.sip
Expand Up @@ -11,7 +11,11 @@ class QgsUniqueValueRenderer : QgsRenderer
/** Determines if a feature will be rendered or not
@param f a pointer to the feature to determine if rendering will happen*/
bool willRenderFeature(QgsFeature *f);
void renderFeature(QPainter* p, QgsFeature& f, QImage* img, bool selected, double widthScale = 1.0, double rasterScaleFactor = 1.0);

/* render feature
* added in 1.2 */
void renderFeature(QgsRenderContext &renderContext, QgsFeature& f, QImage* img, bool selected);

/**Reads the renderer configuration from an XML file
@param rnode the Dom node to read
@param vl the vector layer which will be associated with the renderer*/
Expand Down
2 changes: 2 additions & 0 deletions src/app/CMakeLists.txt
Expand Up @@ -6,6 +6,7 @@ SET(QGIS_APP_SRCS
qgsaddattrdialog.cpp
qgsattributeactiondialog.cpp
qgsattributedialog.cpp
qgsattributeeditor.cpp
qgsattributetypedialog.cpp
qgsattributetypeloaddialog.cpp
qgsbookmarkitem.cpp
Expand Down Expand Up @@ -110,6 +111,7 @@ SET (QGIS_APP_MOC_HDRS
qgsaddattrdialog.h
qgsattributeactiondialog.h
qgsattributedialog.h
qgsattributeeditor.h
qgsattributetypedialog.h
qgsattributetypeloaddialog.h
qgsbookmarks.h
Expand Down

0 comments on commit bbaf61d

Please sign in to comment.