Skip to content

Commit

Permalink
Added GPX Parsing defs
Browse files Browse the repository at this point in the history
  • Loading branch information
wakaba committed Jul 3, 2018
1 parent 0261840 commit 2952f53
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 1 deletion.
7 changes: 6 additions & 1 deletion bin/elements.pl
Expand Up @@ -29,6 +29,8 @@
sub ITUNES1_NS () { q<http://www.itunes.com/dtds/podcast-1.0.dtd> }
sub ITUNES2_NS () { q<http://www.itunes.com/DTDs/Podcast-1.0.dtd> }
sub XSLT_NS () { q<http://www.w3.org/1999/XSL/Transform> }
sub GPX_NS () { q<http://www.topografix.com/GPX/1/1> }
sub GPXEXT_NS () { q<data:,gpx> }

my $NSMAP = {
XML => XML_NS,
Expand All @@ -51,6 +53,8 @@
GDATA => GDATA_NS,
SLASH => SLASH_NS,
XSLT => XSLT_NS,
GPX => GPX_NS,
GPXEXT => GPXEXT_NS,
};
my $NSPATTERN = join '|', keys %$NSMAP;

Expand Down Expand Up @@ -768,7 +772,7 @@
{
my $path = $RootPath->child ('src/element-contents.txt');

my $TextTypePattern = q{text|any|URL|absolute URL|language tag|W3C-DTF|RSS 2\.0 person|RSS 2\.0 date|non-negative integer|MIME type|NPT|floating-point number|currency|e-mail address|itunes:duration|id|XSLT tokens of prefixes|XSLT tokens of elements|XSLT qnames|XSLT expression|XSLT pattern|XSLT prefix or default|XSLT real number|character encoding label|MIME type without charset|QName|NCName|char|language tag or empty};
my $TextTypePattern = q{text|any|URL|absolute URL|language tag|W3C-DTF|RSS 2\.0 person|RSS 2\.0 date|non-negative integer|MIME type|NPT|floating-point number|currency|e-mail address|itunes:duration|id|XSLT tokens of prefixes|XSLT tokens of elements|XSLT qnames|XSLT expression|XSLT pattern|XSLT prefix or default|XSLT real number|character encoding label|MIME type without charset|QName|NCName|char|language tag or empty|time-zone offset string};

my $ens;
my $eln;
Expand All @@ -780,6 +784,7 @@
$def->{url} = $spec if defined $spec;
}
@defined = ();
undef $spec;
};
for (split /\x0D?\x0A/, $path->slurp) {
if (/^\s*#/) {
Expand Down
1 change: 1 addition & 0 deletions doc/data-types.txt
Expand Up @@ -197,6 +197,7 @@ value-type
transfer-coding [RFC7230]
text (Human-readable text)
time string [HTML]
time-zone offset string [HTML]
token68 [RFC7235]
unordered set of unique space-separated tokens [HTML]
URL (URL string [URL])
Expand Down
2 changes: 2 additions & 0 deletions doc/elements.txt
Expand Up @@ -1042,6 +1042,8 @@ compared case-insensitively.

[ARIAHTML] ARIA in HTML <https://w3c.github.io/html-aria/>.

[GPXP] GPX Parsing <https://wiki.suikawiki.org/n/GPX%20Parsing>.

[OBSVOCAB] manakai's Conformance Checking Guideline for Obsolete HTML
Elements and Attributes
<https://suika.suikawiki.org/www/markup/html/exts/manakai-obsvocab>.
Expand Down
12 changes: 12 additions & 0 deletions src/element-contents.txt
Expand Up @@ -2289,3 +2289,15 @@ conforming
XSLT instruction element
spec https://www.w3.org/TR/1999/REC-xslt-19991116#fallback
content XSLT template

* <GPX>gpx

conforming
attr <GPXEXT>tzoffset time-zone offset string
#spec https://wiki.suikawiki.org/n/GPX%20Parsing#header-section-Definitions-of-extensions

* <GPX>trkpt

conforming
attr <GPXEXT>road enum (p|d|u)
#spec https://wiki.suikawiki.org/n/GPX%20Parsing#header-section-Definitions-of-extensions
1 change: 1 addition & 0 deletions src/namespaces.txt
Expand Up @@ -236,3 +236,4 @@ x:
label GPX extension namespace
spec https://wiki.suikawiki.org/n/GPX%20Parsing
limited use
fully supported

0 comments on commit 2952f53

Please sign in to comment.