[QGIS-trac] Re: [Quantum GIS] #1016: mysterious white box obscures data in the map window

Quantum GIS qgis at qgis.org
Wed Aug 20 20:34:40 EDT 2008


#1016: mysterious white box obscures data in the map window
-----------------------------------------------------+----------------------
        Reporter:  rgaston                           |         Owner:  nobody                            
            Type:  patch                             |        Status:  new                               
        Priority:  major: does not work as expected  |     Milestone:  Version 1.0.0                     
       Component:  Graphics                          |       Version:  HEAD                              
      Resolution:                                    |      Keywords:  obscuring box, digitizing, zooming
Platform_version:                                    |      Platform:  All                               
        Must_fix:  No                                |   Status_info:  0                                 
-----------------------------------------------------+----------------------
Changes (by smizuno):

  * type:  defect => patch

Comment:

 I have found that white boxes are caused by the order of setting a new
 size for mMap and mScene in the QgsMapCanvas::resizeEvent(QResizeEvent *
 e) function. I believe that mScene should be set after mMap. The order
 doesn't seem to be a factor except at program startup.

 While I was poking around in QgsMapCanvas.cpp I took the liberty of adding
 zoom in, zoom out abilities by the PageUp, PageDown keys respectively.
 This is something that I had considered for an enhancement as it is useful
 to have zooming if you can pan via the keyboard. Also, not all pointing
 devices have a wheel. They use the zoom function that the mouse wheel zoom
 uses, hence the same zoom factor.

 The patch I have provided fixes the most annoying part of the white box
 problem and adds the keyboard zoom. There still are white boxes that flash
 momentarily when the map is redrawn after certain tools have been used.

 Have tested on Windows and Linux, but not Mac.

-- 
Ticket URL: <http://trac.osgeo.org/qgis/ticket/1016#comment:4>
Quantum GIS <http://qgis.org>
Quantum GIS is an Open Source GIS viewer/editor supporting OGR, PostGIS, and GRASS formats


More information about the QGIS-trac mailing list