[Qgis-developer] Modify FindGEOS.cmake to find a dev version (GEOS_VERSION x.x.xdev)

2014-08-20 Thread Gabriele Monfardini
Hi all,

cmake fails if I try to compile master against a development version of
GEOS,
I've opened an issue with a patch to describe and possibly solve the problem

https://hub.qgis.org/issues/11081

Best regards,

Gabriele Monfardini
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer

[Qgis-developer] Regression in border stylization in a 2.0.1 project, both in 2.2.0 and in trunk

2014-06-25 Thread Gabriele Monfardini
Hi all,

I've opened a bug regarding a regression in border stylization in a 2.0.1
project

https://hub.qgis.org/issues/10723

I've attached a small test case to the bug, in order to easily reproduce
the problem, and obtained results in 2.0.1, 2.2.0 and trunk.

I had several complex project made with 2.0.1 and this bug is a showstopper
to adopt a more recent version, since it would be time consuming to redo
the stylization.

Can someone have a look at it?

Thanks and regards,

Gabriele Monfardini
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [Qgis-developer] Is useasdefault column in public.layerstyles correctly handled when retrieving default style?

2014-06-10 Thread Gabriele Monfardini
Hi all,

I've opened issue http://hub.qgis.org/issues/10523 proposing also a
solution.

May someone confirm this bug and have a look at the proposed solution?

Best regards,

Gabriele Monfardini




On Thu, Jun 5, 2014 at 11:11 AM, Gabriele Monfardini gabrimo...@gmail.com
wrote:

 Hi all,

 in QGIS (trunk updated from git to some days ago, but also in QGIS 2.2 and
 2.0) I have seen a strange behaviour opening a postgis layer in with some
 saved styles in table public.layer_styles.

 All styles have useasdefault set to false (these styles only makes sense
 within some projects, should not be used as default styles).

 When I open the layer without any project, one of the styles is applied,
 in particular the one with update_time more recent.

 The exact query that finds the default style seems to be

 SELECT styleQML FROM layer_styles WHERE f_table_catalog='mydb' AND
 f_table_schema='myschema' AND f_table_name='mytable' AND
 f_geometry_column='the_geom' ORDER BY CASE WHEN useAsDefault THEN 1 ELSE 2
 END,update_time DESC LIMIT 1


 In my opinion rows with useasdefault set to false should be completely
 filtered out by the query.

 If all styles have useasdefault set to false, current query retrieves the
 most recent style while I think that no rows should be retrieved in this
 case and a random color style be applied.

 Thus I propose to change the query in

 SELECT styleQML FROM layer_styles WHERE f_table_catalog='mydb' AND
 f_table_schema='myschema' AND f_table_name='mytable' AND
 f_geometry_column='the_geom'  WHERE useAsDefault ORDER BY update_time DESC
 LIMIT 1

 Would you like me to open a bug?

 Regards,

 Gabriele Monfardini


___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer

[Qgis-developer] Is useasdefault column in public.layerstyles correctly handled when retrieving default style?

2014-06-05 Thread Gabriele Monfardini
Hi all,

in QGIS (trunk updated from git to some days ago, but also in QGIS 2.2 and
2.0) I have seen a strange behaviour opening a postgis layer in with some
saved styles in table public.layer_styles.

All styles have useasdefault set to false (these styles only makes sense
within some projects, should not be used as default styles).

When I open the layer without any project, one of the styles is applied, in
particular the one with update_time more recent.

The exact query that finds the default style seems to be

SELECT styleQML FROM layer_styles WHERE f_table_catalog='mydb' AND
f_table_schema='myschema' AND f_table_name='mytable' AND
f_geometry_column='the_geom' ORDER BY CASE WHEN useAsDefault THEN 1 ELSE 2
END,update_time DESC LIMIT 1


In my opinion rows with useasdefault set to false should be completely
filtered out by the query.

If all styles have useasdefault set to false, current query retrieves the
most recent style while I think that no rows should be retrieved in this
case and a random color style be applied.

Thus I propose to change the query in

SELECT styleQML FROM layer_styles WHERE f_table_catalog='mydb' AND
f_table_schema='myschema' AND f_table_name='mytable' AND
f_geometry_column='the_geom'  WHERE useAsDefault ORDER BY update_time DESC
LIMIT 1

Would you like me to open a bug?

Regards,

Gabriele Monfardini
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [Qgis-developer] Zoom in and out using mouse wheel may use pointer position as center

2013-03-08 Thread Gabriele Monfardini
Thank you all, it works perfectly.
I missed it in the settings panel.

 This is strange - what you describe is already the default in QGIS for
 at least 2-3 years. So maybe you have quite old .qgis settings on your PC?

I have indeed a very old .qgis, it is several years that I compile
qgis from git.
Regards,

Gabriele
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer


[Qgis-developer] Zoom in and out using mouse wheel may use pointer position as center

2013-03-07 Thread Gabriele Monfardini
Hi all,

zooming in and out in qgis using mouse wheel does not change canvas center.
Why don't use current mouse position as center?

This would allow zooming to a small region without panning, with the
following steps:

1. position mouse in the desired position
2. zoom in with mouse wheel (desired position never exit the canvas)

Currently user usually do:

1. zoom in with mouse wheel until desired position exit the canvas
2. pan to recenter canvas around desired position. Due to the
imprecision of this operation zooming in a lot desired position may
exit the canvas again
3. repeat 1+ 2 until needed

Regards,

Gabriele Monfardini
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer


[Qgis-developer] In PostGIS vectors selection dialog Shift+click does not select a range

2012-09-21 Thread Gabriele Monfardini
I'm on master, on Linux 64bit.

In PostGIS vectors selection dialog Shift+click does not select a
range, but selects the current layer as Shift was not pressed.

In other places (f.i. in the legend, shift+click works as expected).
Should I open a bug?

Regards,

Gabriele Monfardini
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer


[Qgis-developer] Colors selection when adding multiple layers could be improved

2012-09-21 Thread Gabriele Monfardini
When adding multiple layers to a map for quick data inspection,
initial color selection is not perfect.

It happens often that some colors are very similar and I have to
change some of them in order to distinguish them better
The very first colors may be chosen to be visually quite different
from each other.

Regards,

Gabriele Monfardini
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer


[Qgis-developer] finding custom svg from project file assumes only on level of directories under SvgPath

2012-03-22 Thread Gabriele Monfardini
Hi all,

I've probably found a bug in using a custom svg for symbology.
I've tested it in 1.7.4 and master.

In order to use a custom svg file I've dropped it into
~homedir/.qgis/svg/custom_directory/custom_subdirectory

I'm able to use the svg both with 1.7.4 and with master.
I see it in the list of svgs, I can select it and it is drawn
correctly, its path is correctly saved in project file (1.7.4
version).

However reopening the project qgis 1.7.4 is not able to find the file,
resulting in

Warning: QFSFileEngine::open: No file name specified
Warning: Cannot open file '', because: No file name specified


custom_directory = custom
custom_subdirectory = ctr

Also master code is not able to find svg, and Debug version log the
following lines

Debug: src/core/symbology-ng/qgsmarkersymbollayerv2.cpp: 798:
(symbolNameToPath) SvgPath: /usr/local/share/qgis/svg/
Debug: src/core/symbology-ng/qgsmarkersymbollayerv2.cpp: 804:
(symbolNameToPath) Alternative svg path:
/usr/local/share/qgis/svg//ctr/0706.svg
Debug: src/core/symbology-ng/qgsmarkersymbollayerv2.cpp: 827:
(symbolNameToPath) Computed alternate path but no svg there either
Debug: src/core/symbology-ng/qgsmarkersymbollayerv2.cpp: 798:
(symbolNameToPath) SvgPath: /home/monfardini/.qgis//svg/
Debug: src/core/symbology-ng/qgsmarkersymbollayerv2.cpp: 804:
(symbolNameToPath) Alternative svg path:
/home/monfardini/.qgis//svg//ctr/0706.svg --
Debug: src/core/symbology-ng/qgsmarkersymbollayerv2.cpp: 827:
(symbolNameToPath) Computed alternate path but no svg there either

The directory custom has been wiped from the path (it should be
/home/monfardini/.qgis//svg/custom/ctr/0706.svg instead of
/home/monfardini/.qgis//svg//ctr/0706.svg)

so it appears that code assumes only one level of directories under SvgPath

I've opened the following bug: http://hub.qgis.org/issues/5222

Regards,

Gabriele
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer


Re: [Qgis-developer] QGIS master flickering on mouse moving

2012-02-14 Thread Gabriele Monfardini
I've filed bug  #5008, suggesting that it may be related to #4011.

Regards,

Gabriele Monfardini


On Fri, Feb 10, 2012 at 12:35, Gabriele Monfardini gabrimo...@gmail.com wrote:
 An update on flickering I'm experiencing, since the problem is a bit
 more complicated than I've described in previous mail.

 The flickering happens when:

 * qgis window grab/lost the focus
 * mouse enter/exit map canvas but ONLY if qgis window does not have
 the focus (and this is the reason that in my previous mail I've
 wrongly said that it was no more present, I was indeed trying with
 qgis window having the focus)
 * dragging content as of ticket 4011 (http://hub.qgis.org/issues/4011)

 Are more info needed?
 Is there anything I can try to see if it is really a bug or just
 something in my setup?

 Regards,

 Gabriele Monfardini
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer


Re: [Qgis-developer] QGIS master flickering on mouse moving

2012-02-09 Thread Gabriele Monfardini
Hi Alexander, hi all,

today (last revision 2cea3494ebdd0777211b7abac53c86a8f40bca71) the
problem has disappeared.
I'll keep compiling qgis in the following days and reports here if the
problem reappears.

Regards,

Gabriele Monfardini
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer


[Qgis-developer] QGIS master flickering on mouse moving

2012-02-08 Thread Gabriele Monfardini
Hi all,

I'm on git master up-to-date (last commit
aaddc4f914dc750afeb4395c6f1254f584161f4f).


Versione di QGIS   1.9.90-Alpha
QGIS code revision3f50017
Compiled against Qt  4.7.4
Running against Qt4.7.4
GDAL/OGR Version   1.9.0
GEOS Version   3.4.dev
PostgreSQL Client Version  9.1.2
SpatiaLite Version  2.4.0
QWT Version 5.2.2


Starting from a couple of days QGIS flicker evidently when moving the
cursor in and out map canvas.

There is no log from QGIS, no log from Xorg, nor entries in syslog.
Toggling the checkbox Update does not have any effect, so flickering
is not due to updating the view.

My video card is a Radeon HD 3450, with radeon driver.
I'm on kubuntu oneiric.

Toggling desktop effects in my desktop manager (kdm) also does not
have any effects.
Toggling compositing type from OpenGL and Xrender also does not have
any effects.

I cannot remember if this problem was present also in kde 4.7 (I've
updated to kde 4.8 a few days ago).

Can anyone confirm this?

Regards,

Gabriele Monfardini
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer


[Qgis-developer] cppcheck report

2011-04-29 Thread Gabriele Monfardini
Hi all,

I've runned cppcheck on source code revision 15849.
This is the report.

[./app/qgsmaptooladdvertex.cpp:111]: (error) Dangerous iterator usage.
After erase the iterator is invalid so dereferencing it or comparing
it with another iterator is invalid.
[./app/qgssinglesymboldialog.cpp:149]: (error) Possible null pointer
dereference: mVectorLayer - otherwise it is redundant to check if
mVectorLayer is null at line 223
[./core/pal/problem.cpp:2461]: (error) Memory leak: solution
[./core/qgsgeometry.cpp:1565]: (error) Mismatching allocation and
deallocation: newbuffer
[./core/qgsgeometry.cpp:1621]: (error) Mismatching allocation and
deallocation: newbuffer
[./core/qgsgeometry.cpp:1679]: (error) Mismatching allocation and
deallocation: newbuffer
[./core/qgsgeometry.cpp:1757]: (error) Mismatching allocation and
deallocation: newbuffer
[./core/qgsgeometry.cpp:1879]: (error) Mismatching allocation and
deallocation: newbuffer
[./core/qgsgeometry.cpp:2129]: (error) Mismatching allocation and
deallocation: newbuffer
[./core/qgsgeometry.cpp:4802]: (error) Mismatching allocation and
deallocation: newGeometry
[./core/spatialite/spatialite.c:124214]: (error) Memory leak: p
[./core/spatialite/spatialite.c:169967]: (error) Memory leak: p
[./core/spatialite/spatialite.c:170206]: (error) Memory leak: p
[./core/spatialite/sqlite3.c:14405]: (error) Common realloc mistake:
p nulled but not freed upon failure
[./mapserver/qgssldparser.cpp:1408]: (error) Mismatching allocation
and deallocation: adfFixedLevels
[./plugins/dxf2shp_converter/shapelib-1.2.10/dbfopen.c:540]: (error)
Memory leak: pszFullname
[./plugins/dxf2shp_converter/shapelib-1.2.10/shpopen.c:458]: (error)
Memory leak: pabyBuf
[./plugins/dxf2shp_converter/shapelib-1.2.10/shpopen.c:657]: (error)
Memory leak: pszBasename
[./plugins/dxf2shp_converter/shapelib-1.2.10/shpopen.c:657]: (error)
Memory leak: pszFullname
[./plugins/dxf2shp_converter/shapelib-1.2.10/shpopen.c:662]: (error)
Resource leak: fpSHP
[./providers/grass/qgsgrassprovider.cpp:407]: (error) Common realloc
mistake: wkb nulled but not freed upon failure

Regards,

Gabriele Monfardini
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer


Re: [Qgis-developer] Unable to compile QGIS under Ubuntu 10.04 LTS

2010-11-08 Thread Gabriele Monfardini
I think you need to compile against /usr/lib/libqwt-qt4.so instead of
/use/lib/libqwt.so.
You can fix the problem removing the package that provide libqwt.so, install
the one that provide libqwt-qt4.so, doing cmake again and verifying what
cmake said in Found QWT: line.
Regards,

Gabriele
Il giorno 2010 11 8 15:39, luca_mangane...@comune.trento.it ha scritto:

 Hi,

 I'm encounteering problems compiling latest SVN build of QGIS. I have this
 error:

 [ 44%] Building CXX object src/app/CMakeFiles/qgis.dir/qgisapp.cpp.o
 In file included from
 /usr/local/src/qgis_unstable/src/app/qgsrasterlayerproperties.h:23,
 from /usr/local/src/qgis_unstable/src/app/qgisapp.cpp:145:

 [...]

 /usr/local/src/qgis_unstable/src/app/gps/qgsgpsinformationwidget.h:75:
 error: expected \u2018;\u2019 before \u2018*\u2019 token
 /usr/local/src/qgis_unstable/src/app/qgisapp.cpp: In member function 'void
 QgisApp::about()':
 /usr/local/src/qgis_unstable/src/app/qgisapp.cpp:2496: error:
 'QWT_VERSION_STR' was not declared in this scope
 make[2]: *** [src/app/CMakeFiles/qgis.dir/qgisapp.cpp.o] Errore 1
 make[1]: *** [src/app/CMakeFiles/qgis.dir/all] Errore 2
 make: *** [all] Errore 2


 It seems that QWT is missing, BUT (note the directory)

 /usr/include/qwt-qt4 $ fgrep QWT_VERSION_STR *

 qwt_global.h:#define QWT_VERSION_STR 5.2.0

 It is also found by CMAKE:

 /usr/local/src/qgis_unstable/cmake$ cmake .

 -- Quantum GIS version: 1.7.0 Trunk (10700)
 -- Could not find GRASS
 -- Found Proj: /usr/lib/libproj.so
 -- Found Expat: /usr/lib/libexpat.so
 -- Found GSL: -L/usr/lib -lgsl -lgslcblas -lm
 -- Found GEOS: /usr/local/lib/libgeos_c.so
 -- Found GDAL: /usr/local/lib/libgdal.so
 -- Found QWT: /usr/lib/libqwt.so
 -- Found PostgreSQL: /usr/lib/libpq.so
 -- Debug output enabled
 -- Found Python executable: /usr/bin/python2.6
 -- Found Python version: 2.6.5
 -- Found Python library: /usr/lib/libpython2.6.so
 -- Found SIP version: 4.10.1
 -- Found PyQt4 version: 4.7.2
 -- Found FCGI: /usr/lib/libfcgi.so
 -- Configuring done
 -- Generating done
 -- Build files have been written to: /usr/local/src/qgis_unstable/cmake


 how can I fix this error?

 ___
 Qgis-developer mailing list
 Qgis-developer@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/qgis-developer
___
Qgis-developer mailing list
Qgis-developer@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-developer