Skip to content

Relative file path in JOSM session file #6

Description

@cshaa

In a session.jos file, the other layers can be specified by paths relative to the session file:

<?xml version="1.0" encoding="utf-8"?>
<josm-session version="0.1">
    <layers active="1">
        <layer index="1" name="data_layer.osm" type="osm-data" version="0.1" visible="true">
            <file>./data.osm</file>
        </layer>
        <layer index="2" name="google_contours.osm" type="osm-data" version="0.1" visible="true">
            <file>./contours.osm</file>
        </layer>
    </layers>
</josm-session>

However, if I try to include a pic layer using a relative path:

<layer index="3" name="p69_001.png" type="piclayerImage" version="0.1" visible="true">
    <piclayerImage>
        <file>./my_pic.png</file>
        <thumbnail>false</thumbnail>
    </piclayerImage>
</layer>

I get an error:
image

The only way to get the image to load is by using a full absolute path. This ruins the portability of a session file that would otherwise work across different machines.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions