jira.codehaus.org

  • Log In Access more options
    • Online Help
    • Keyboard Shortcuts
    • About JIRA
    • JIRA Credits
    • What?s New
  • Dashboards Access more options (Alt+d)
  • Projects Access more options (Alt+p)
  • Issues Access more options (Alt+i)
  • GeoTools
  • GEOT-653

Support Text objects in MIFDataStore

  • Log In
  • Views
    • XML
    • Word
    • Printable

Details

  • Type: New Feature New Feature
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Won't Fix
  • Affects Version/s: None
  • Fix Version/s: 2.7-M0
  • Component/s: unsupported
  • Labels:
    None

Description

Currently MIFDataStore does not support MapInfo Text objects.

A MapInfo text object, rather that being a label attached to a point, is like a text written (often with a very large brush) on the earth's surface, so that the rendering size is affected by the current map zoom.

A Text object has the following attributes:

Text string (label)
boundary (x1, y1, x2, y2) (which is not an MBR thus)
Angle (label rotation)
can have a line with x,y coordinates of the arrow point
style info: font, size, spacing etc...

Given that MIFDataStore does not support style at the feature level, we should at least save the text and a Geometry to which we should attach it, maybe a point or a rect.

MIFDataStore could either:

1. Define a Text class derived from Geometry which could behave like a
point or rect, and offer storage for text attributes; this could cause
compatibility problems with other GeoTools components, but I'm not sure
about this;

or

2. Read text objects as if they were points (or rects) storing the
text string and angle in Feature attributes. The Feature could have
TEXT_ANGLE, TEXT_LABEL, TEXT_SPACING attributes. This could make
difficult implementing a write support for this kind of objects, which would be written as point or polygon in MIF format.

Activity

Ascending order - Click to sort in descending order
  • All
  • Comments
  • History
  • Activity
Hide
Permalink
Luca S. Percich added a comment - 22/Aug/05 5:28 AM
A simple way to attach MapInfo-specific information could be using a Properties object, which could be stored either in the the Geometry.userData without altering the Feature structure, or in the feature structure in a MIF_PROPERTIES field (as a Properties object or converted to a String).

This could allow for mantaining MapInfo specific types which are not mappable to JTS types, as well as MapInfo style information "as is". Both issues are useful for saving data back to the MIF file without loosing the original structure.

The following properties could optionally be saved, (all have string values):

# SYMBOL = shape,color,size
# PEN = width, pattern, color
# BRUSH=pattern,forecolor,backcolor
# CENTER=x,y (polygon centroid)
# SMOOTH=yes|no
# FONT=
# SPACING=1|1.5|2
# JUSTIFY=l|r|c
# TEXT_ANGLE=...
# ROUNDING=... (for roundrect)
# LABEL_LINE={simple|arrow},x,y
# ARC_BEGANGLE=...
# ARC_ENDANGLE=...
# MAPINFO_TYPE=line,arc,text,rect,roundrect,ellipse (for unsupported geom types)
Show
Luca S. Percich added a comment - 22/Aug/05 5:28 AM A simple way to attach MapInfo-specific information could be using a Properties object, which could be stored either in the the Geometry.userData without altering the Feature structure, or in the feature structure in a MIF_PROPERTIES field (as a Properties object or converted to a String). This could allow for mantaining MapInfo specific types which are not mappable to JTS types, as well as MapInfo style information "as is". Both issues are useful for saving data back to the MIF file without loosing the original structure. The following properties could optionally be saved, (all have string values): # SYMBOL = shape,color,size # PEN = width, pattern, color # BRUSH=pattern,forecolor,backcolor # CENTER=x,y (polygon centroid) # SMOOTH=yes|no # FONT= # SPACING=1|1.5|2 # JUSTIFY=l|r|c # TEXT_ANGLE=... # ROUNDING=... (for roundrect) # LABEL_LINE={simple|arrow},x,y # ARC_BEGANGLE=... # ARC_ENDANGLE=... # MAPINFO_TYPE=line,arc,text,rect,roundrect,ellipse (for unsupported geom types)
Hide
Permalink
Michael Bedward added a comment - 23/May/10 3:29 AM
closing old issue - interest apparently waned
Show
Michael Bedward added a comment - 23/May/10 3:29 AM closing old issue - interest apparently waned

People

  • Assignee:
    Luca S. Percich
    Reporter:
    Luca S. Percich
Vote (0)
Watch (0)

Dates

  • Created:
    05/Aug/05 9:04 AM
    Updated:
    02/Jun/11 9:26 AM
    Resolved:
    23/May/10 3:29 AM
  • Atlassian JIRA (v5.0.4#731-sha1:3aa7374)
  • Report a problem
  • Powered by a free Atlassian JIRA open source license for Codehaus. Try JIRA - bug tracking software for your team.