Opened 13 years ago

Closed 13 years ago

#3863 closed patch (fixed)

Bookmarks fixes and enhancements

Reported by: smizuno Owned by: nobody
Priority: major: does not work as expected Milestone: Version 1.7.0
Component: GUI Version: Trunk
Keywords: Cc:
Must Fix for Release: No Platform: All
Platform Version: Awaiting user input: no

Description

After some extensive use of bookmarks to explore scattered areas on a map I found some problems with the Bookmarks tool as well as some missing functionality that is very useful to have. I am offering a patch to fix and improve Bookmarks.

Here are the issues:

  1. a bookmark fails (silently) to store if it has a single-quote in the name (or project name). The quote mark is now escaped before inserting the text in the database.
  1. double-click on a bookmark item did not work (help says you can) due to an incorrect slot name. The automatic signal/slot binding didn't work because of this. This fixes #2774
  1. the stored precision of the extent was limited to 6 digits. I believe that full floating point precision (17 digits) should be preserved, so the number output precision is set to 17.
  1. have to delete a bookmark, then create a new one in order to update the extent. I have provided an Update button to do this as well as help text on its use.

In the process of working out the coding for the fixes and improvements, I have:

+ reworked some of the Sqlite calls to simplify them as I found them complicated to understand

+ put the call to restorePosition in QgsBookmarks constructor instead of QgisApp. It makes little sense to have the main program call restore if the saving was done in the destructor.

Attachments (1)

patch-for-3863.txt (9.9 KB ) - added by smizuno 13 years ago.
patch Bookmarks

Download all attachments as: .zip

Change History (2)

by smizuno, 13 years ago

Attachment: patch-for-3863.txt added

patch Bookmarks

comment:1 by jef, 13 years ago

Resolution: fixed
Status: newclosed

applied in 9ae32d32b2cbc82eee29e550f6b2a2b33d3043e4.

Note: See TracTickets for help on using tickets.