From b0ea6e3d2705778be5e6ff8d079c72278d06b7b7 Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Sun, 13 Mar 2016 17:39:49 -0700 Subject: [PATCH] Work on "format" element. --- spv-file-format.texi | 61 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) diff --git a/spv-file-format.texi b/spv-file-format.texi index 1eb9a3ef52..15eef0eedf 100644 --- a/spv-file-format.texi +++ b/spv-file-format.texi @@ -1879,3 +1879,64 @@ and earlier, @code{setFormat} contains one of a number of child elements that correspond to the different varieties of print formats. In version 2.7 and later, @code{setFormat} instead always contains a @code{format} element. + +@subsubheading The @code{format} Element + +Parent: @code{sourceVariable}, @code{derivedVariable}, @code{formatMapping}, @code{labeling}, @code{formatMapping}, @code{setFormat} @* +Contents: (@code{affix}@math{+} @math{|} @code{relabel})? + +This element determines a format, equivalent to an SPSS print format. +The following attribute determines the high-level kind of formatting +in use: + +@defvr {Optional} baseFormat +One of @code{date}, @code{time}, @code{dateTime}, or +@code{elapsedTime}. When this attribute is omitted, this element is a +numeric or string format. +@end defvr + +@noindent +Whether other attributes are required (``yes''), prohibited (``no''), +or optional (``opt'') depends on @code{baseFormat}: + +@multitable {maximumFractionDigits} {@code{dateTime}} {@code{elapsedTime}} {number} {string} +@headitem Attribute @tab @code{dateTime} @tab @code{elapsedTime} @tab number @tab string +@item errorCharacter @tab yes @tab yes @tab yes @tab opt +@item maximumFractionDigits @tab no @tab yes @tab yes @tab no +@item minimumFractionDigits @tab no @tab yes @tab yes @tab no +@item separatorChars @tab yes @tab no @tab no @tab no +@item +@item useGrouping @tab no @tab opt @tab no @tab no +@item mdyOrder @tab yes @tab no @tab no @tab no +@item +@item showYear @tab yes @tab no @tab no @tab no +@item yearAbbreviation @tab yes @tab no @tab no @tab no +@item +@item showMonth @tab yes @tab no @tab no @tab no +@item monthFormat @tab yes @tab no @tab no @tab no +@item +@item showDay @tab yes @tab opt @tab no @tab no +@item dayPadding @tab yes @tab opt @tab no @tab no +@item dayOfMonthPadding @tab yes @tab no @tab no @tab no +@item dayType @tab yes @tab no @tab no @tab no +@item +@item showHour @tab yes @tab opt @tab no @tab no +@item hourFormat @tab yes @tab opt @tab no @tab no +@item hourPadding @tab yes @tab yes @tab no @tab no +@item +@item showMinute @tab yes @tab no @tab no @tab no +@item minutePadding @tab yes @tab yes @tab no @tab no +@item +@item showSecond @tab yes @tab yes @tab no @tab no +@item secondPadding @tab no @tab yes @tab no @tab no +@item +@item showMillis @tab no @tab yes @tab no @tab no +@item +@item tryStringsAsNumbers @tab no @tab no @tab no @tab no +@item +@item minimumIntegerDigits @tab no @tab no @tab yes @tab no +@item scientific @tab no @tab no @tab yes @tab no +@item small @tab no @tab no @tab opt @tab no +@item +@item suffix @tab no @tab no @tab opt @tab no +@end multitable -- 2.30.2