MapGuide Open Source:  Home |  Download |  Internals

Ticket #797 (closed enhancement: fixed)

Opened 1 year ago

Last modified 1 year ago

Patch to change the active tool Cursor in ajax viewer

Reported by: bscott Assigned to: waltweltonlair
Priority: medium Milestone: 2.2
Component: AJAX Viewer Version: 2.0.2
Severity: trivial Keywords:
Cc: External ID:

Description

The Community code sample Displaying custom cursors when the zoom tool is selected would add a real value to the final product if it was included in the ajaxviewer.

There's a thread in nable that tack about it http://www.nabble.com/Patch-to-change-the-active-tool-Cursor-in-ajax-viewer-td20789750.html

I can't figure out how to attach binary cursor files in a diff patch, so i have attached them in a separate zip files

Attachments

Patch_icons.patch (1.0 kB) - added by bscott on 12/16/08 11:21:45.
patch_stdicons.zip (2.7 kB) - added by bscott on 12/22/08 05:13:38.
cursors.zip (1.6 kB) - added by tomfukushima on 01/12/09 15:30:50.
Alternate set of cursors created by Autodesk product design
mapguide_allcursor.patch (6.0 kB) - added by bscott on 01/15/09 09:45:19.
MapguideCursorBig.zip (8.8 kB) - added by bscott on 01/15/09 10:27:05.
cursorsNew.zip (4.6 kB) - added by waltweltonlair on 03/13/09 18:05:56.
Update set of alternate cursors created by Autodesk product design

Change History

12/16/08 11:21:45 changed by bscott

  • attachment Patch_icons.patch added.

12/20/08 00:32:36 changed by tomfukushima

Before I apply the patch, please do the following: Set appropriate hotspots on all the cursors. They are currently all set to 0,0 but that is quite far away from the actual cursor image. The hotspot for the pan cursor does not really matter, but it would be good to center it on the hand. The hotspot for the zoom in and out should be at the center of the + and - in the magnifier glass area. It's not as apparent where to put the hotspot for the zoom rectangle, but perhaps we could try putting a + in the center of the magnifying glass and use that as the hotspot. Thanks, Tom

12/20/08 00:35:55 changed by tomfukushima

Also, please state the source of those cursors. We don't want to run into any copyright problems.

12/22/08 05:13:38 changed by bscott

  • attachment patch_stdicons.zip added.

12/22/08 05:21:03 changed by bscott

Thanks for the comments Tom, So i have fixed all the hot spots and i have also fixed the alpha chanels, so the transparency is cleaner. The sources or the previous cursors files was the one i founded in the Mapguide Community sample codes, These one have been created ( by me ) using the gif files in the mapguide stdicons directory.

01/08/09 13:08:54 changed by tomfukushima

Hi,

The icons look pretty good. Our product designer may create a replacement set that are a little more generic; but there probably won't be time. Otherwise, if you could make them a little bigger so that they are clearer that would be good. Also, I don't think that the pan cursor needs the + on it.

Our product designer noted following problems that will need to be corrected before submission:

  1. Open the web layout in the browser. Select the Zoom rectangle mode (notice that the cursor is correctly changed to the zoom rectangle cursor). Do a zoom operation. Do a "zoom previous" operation. Notice that even though the map is still in the "zoom rectangle" mode the cursor is now incorrectly the select cursor.
  2. Open the web layout in the browser. Select the zoom rectangle mode. Select the measure distance task. Notice that the cursor is still the zoom rectangle cursor even though the map is now in measure distance mode.

The above problems mention Zoom rectangle, but probably also affect the other modes.

01/12/09 15:30:50 changed by tomfukushima

  • attachment cursors.zip added.

Alternate set of cursors created by Autodesk product design

01/13/09 11:04:01 changed by bscott

Hi tom, I have made all the fixes you requested, plus others. I took a more global approach, so i have overridden all cursors

Measure SelectPolygon? SelectRadius? DigitizePoint? DigitizeLine? DigitizeLineString? DigitizeCircle? DigitizeRectangle? DigitizePolygon?

All these cursors a bigger than the initial versions

Bruno

01/14/09 15:16:19 changed by tomfukushima

Hi Bruno, Thanks for the changes. Problem 2 above was resolved, but I can still reproduce 1. Try these steps...

  1. Open the Sheboygan sample map
  2. Select the Zoom rectangle mode
  3. Do a zoom rectangle operation to zoom in
  4. Click on the Zoom menu on the toolbar, and select "Previous View"

Note that after the map zooms back to the previous view, the cursor is now the select cursor when it should still be the zoom rectangle cursor. The same problem occurs with Zoom in mode, Zoom out mode, pan mode, etc.

01/15/09 09:44:52 changed by bscott

Oops Sorry, i forgot that little point :( I've replaced the mapguide_allcursor patch with a fixed one

Bruno

01/15/09 09:45:19 changed by bscott

  • attachment mapguide_allcursor.patch added.

01/15/09 10:27:05 changed by bscott

  • attachment MapguideCursorBig.zip added.

01/15/09 10:28:12 changed by bscott

I've just replace one of the cursor, the ZoomRect?.cur had a plus sign and should not. Bruno

03/13/09 18:05:56 changed by waltweltonlair

  • attachment cursorsNew.zip added.

Update set of alternate cursors created by Autodesk product design

03/13/09 18:06:26 changed by waltweltonlair

  • owner set to waltweltonlair.
  • status changed from new to assigned.
  • milestone changed from 2.1 to 2.2.

03/13/09 18:43:48 changed by waltweltonlair

  • status changed from assigned to closed.
  • resolution set to fixed.

Fixed in the trunk stream with submission https://trac.osgeo.org/mapguide/changeset/3735.

I used the Autodesk-supplied cursors.

Thanks bscott for providing this nice patch.