Grids - new coordinate system
Hi all, We have to change the coordinate system used by grids in XML. I think it is the only thing left that has the inverted coord-system in XML. I changed it in the guides improvements branch, and it works fine. The only problem is: grids of old files will show wrong, they are not "upgraded" to the new format, because there is (yet) no way to distinguish old-style from new-style grids. How should I go about this? It is relatively easy to fix it manually for each file, but I understand it is an annoyance.
Cheers, Johan
2013/3/31 Johan Engelen <jbc.engelen@...2592...>:
Hi all, We have to change the coordinate system used by grids in XML. I think it is the only thing left that has the inverted coord-system in XML.
The second big offender is 3D box.
I changed it in the guides improvements branch, and it works fine. The only problem is: grids of old files will show wrong, they are not "upgraded" to the new format, because there is (yet) no way to distinguish old-style from new-style grids. How should I go about this? It is relatively easy to fix it manually for each file, but I understand it is an annoyance.
Some ideas: a) Use a different element name for the new grids, for instance inkscape:grid2. b) Add some kind of attribute, e.g. version="1" or coordinate-system="document" on the new grid element.
Regards, Krzysztof
On 2-4-2013 15:45, Krzysztof Kosiński wrote:
2013/3/31 Johan Engelen <jbc.engelen@...2592...>:
Hi all, We have to change the coordinate system used by grids in XML. I think it is the only thing left that has the inverted coord-system in XML.
The second big offender is 3D box.
I changed it in the guides improvements branch, and it works fine. The only problem is: grids of old files will show wrong, they are not "upgraded" to the new format, because there is (yet) no way to distinguish old-style from new-style grids. How should I go about this? It is relatively easy to fix it manually for each file, but I understand it is an annoyance.
Some ideas: a) Use a different element name for the new grids, for instance inkscape:grid2. b) Add some kind of attribute, e.g. version="1" or coordinate-system="document" on the new grid element.
a) Definitely the easiest choice. This is effectively what we did for the new guides too. pre-0.49 will not be able to see grids and guides.
b) More flexible solution. Can preserve forward-compatibility for pre-0.49. But much more work.
Just now I remember that the coord change for guides and grids now breaks all UI spinboxes that show the y-coordinate of the grid origin / guides. So additional work is needed to clean that up. Because we have a GSoC student interested in improving the guide UI, I am thinking about keeping the grid/guide stuff in the branch for now and have the student work on that.
Cheers, Johan
2013/4/7 Johan Engelen <jbc.engelen@...2592...>:
Some ideas: a) Use a different element name for the new grids, for instance inkscape:grid2. b) Add some kind of attribute, e.g. version="1" or coordinate-system="document" on the new grid element.
a) Definitely the easiest choice. This is effectively what we did for the new guides too. pre-0.49 will not be able to see grids and guides.
I think this is acceptable; we should only avoid displaying 'broken' grids / guides, where the grid is visible but in the wrong place. It should either work correctly or not at all.
b) More flexible solution. Can preserve forward-compatibility for pre-0.49. But much more work.
I don't think it's worth adding this sort of gratuitious complexity. Saving in old formats is a must for proprietary applications, where each new version costs money. In our case it would only be useful if there are severe regressions, and we should do our best to avoid that anyway.
Regards, Krzysztof
On 8-4-2013 15:31, Krzysztof Kosiński wrote:
2013/4/7 Johan Engelen <jbc.engelen@...2592...>:
Some ideas: a) Use a different element name for the new grids, for instance inkscape:grid2. b) Add some kind of attribute, e.g. version="1" or coordinate-system="document" on the new grid element.
a) Definitely the easiest choice. This is effectively what we did for the new guides too. pre-0.49 will not be able to see grids and guides.
I think this is acceptable; we should only avoid displaying 'broken' grids / guides, where the grid is visible but in the wrong place. It should either work correctly or not at all.
b) More flexible solution. Can preserve forward-compatibility for pre-0.49. But much more work.
I don't think it's worth adding this sort of gratuitious complexity. Saving in old formats is a must for proprietary applications, where each new version costs money. In our case it would only be useful if there are severe regressions, and we should do our best to avoid that anyway.
Yeah, I guess you are right. It would be "over-featured". Ok, so I'll go for the inkscape:grid2 thing then. Thanks for the feedback.
Cheers, Johan
On Apr 13, 2013, at 1:21 PM, Johan Engelen wrote:
On 8-4-2013 15:31, Krzysztof Kosiński wrote:
2013/4/7 Johan Engelen <jbc.engelen@...2592...>:
Some ideas: a) Use a different element name for the new grids, for instance inkscape:grid2. b) Add some kind of attribute, e.g. version="1" or coordinate-system="document" on the new grid element.
a) Definitely the easiest choice. This is effectively what we did for the new guides too. pre-0.49 will not be able to see grids and guides.
I think this is acceptable; we should only avoid displaying 'broken' grids / guides, where the grid is visible but in the wrong place. It should either work correctly or not at all.
b) More flexible solution. Can preserve forward-compatibility for pre-0.49. But much more work.
I don't think it's worth adding this sort of gratuitious complexity. Saving in old formats is a must for proprietary applications, where each new version costs money. In our case it would only be useful if there are severe regressions, and we should do our best to avoid that anyway.
Yeah, I guess you are right. It would be "over-featured". Ok, so I'll go for the inkscape:grid2 thing then. Thanks for the feedback.
I'd look into making things compatible when we can. In this case I know there were some past discussions, and some came up with a few approaches that could get compatibility without too much effort.
I'll see if I can dig some of these up.
On Apr 7, 2013, at 6:43 AM, Johan Engelen wrote:
a) Definitely the easiest choice. This is effectively what we did for the new guides too. pre-0.49 will not be able to see grids and guides.
b) More flexible solution. Can preserve forward-compatibility for pre-0.49. But much more work.
Just now I remember that the coord change for guides and grids now breaks all UI spinboxes that show the y-coordinate of the grid origin / guides. So additional work is needed to clean that up. Because we have a GSoC student interested in improving the guide UI, I am thinking about keeping the grid/guide stuff in the branch for now and have the student work on that.
Hi Johan,
Can you get a quick summary of the differences and problems up onto the wiki?
I think I have a general solution that would work for grids and guides alike, and it won't be significantly more work at all. However, getting a clear statement of the actual issues to be addressed will help clarify.
participants (3)
-
Johan Engelen
-
Jon Cruz
-
Krzysztof Kosiński