.. highlightlang:: us .. index:: ObjGetXML .. _ObjGetXML: ObjGetXML ========= .. us.tag ObjGetXML GERMAN New5505 Changed5800 :ref:`ObjGetXML` liefert eine Dokument-Seite, ein Diagramm, ein Zeichenobjekt oder einen Datensatz als XML-Text. .. function:: ssXML = ObjGetXML(hObj) ssXML = ObjGetXML(hObj, bEdit) .. us.return **Returnwert** *ssXML*. .. us.params **Parameter** .. uparam:: hObj *hObj* ist die Zugriffsnummer einer Seite, eines Diagramms, eines Zeichenobjekts oder eines Datensatzes. .. uparam:: bEdit Wenn *bEdit* gleich TRUE (1) ist, wird der XML-Text formatiert in einen Editor kopiert. .. us.comment **Kommentar** .. note:: Diese Funktion ist eine Beta-Version. Die Release-Version wird in einem der nächsten Updates fertig gestellt. .. us.history **History** .. list-table:: :header-rows: 1 * - Version - Beschreibung * - R2013.5 - Neu. .. seealso:: :ref:`uberblick-objekte`, :ref:`ObjCreateXML` .. highlight:: none XML-Schema ---------- page ^^^^ Beispiel: .. code-block:: xml :linenos: ... .. relax :: page = element page { attlist_page, maps?, layer* } attlist_page &= attribute name { text }, attribute version { text }, attribute orientation { text }?, attribute width { xsd:double }?, attribute height { xsd:double }?, attribute margin { xsd:boolean }?, ## PageGetBackgroundPageName attribute background-page-name { text }? .. relax-end layer ^^^^^ .. relax :: bkmode = list { (xsd:string "opaque" | xsd:string "transparent")+ } bk_atts = attribute bkmode { bkmode }?, ## 0: ohne Farbverlauf 1: mit Farbverlauf attribute gradient { xsd:boolean }?, attribute gradient-colors {string}?, attribute fill-color { color }? layer = element layer { attlist_layer, axes?, maps?, shapes?, datasets? } attlist_waterfall = attribute waterfall-closebox { xsd:boolean }?, attribute waterfall-frontgrid { xsd:boolean }?, attribute waterfall-reverseorder { xsd:boolean }?, attribute waterfall-dx { xsd:double }?, attribute waterfall-dy { xsd:double }?, attribute waterfall-label-freq { xsd:int }?, attribute waterfall-label-type { xsd:int }? attlist_polar = attribute polar-rad-label-opaque { xsd:boolean }?, attribute polar-angle-label-opaque { xsd:boolean }?, attribute polar-angle-label-gradient { xsd:boolean }?, attribute polar-clockwise { xsd:boolean }?, attribute polar-draw-to-center-freq { xsd:int }?, attribute polar-draw-to-center-offset-major { xsd:int }?, attribute polar-draw-to-center-offset-minor { xsd:int }?, attribute polar-min-radius { xsd:double }?, attribute polar-angle-offset { xsd:double }? attlist_3d = attribute view-3d-box { xsd:boolean }?, attribute view-3d-distance { xsd:double }?, attribute view-3d-elevation { xsd:double }?, attribute view-3d-rotation { xsd:double }?, attribute view-3d-box-ratio { list { xsd:double, xsd:double, xsd:double} }? attlist_layer = attribute name { text }, xy_width_height, attribute background { xsd:boolean }?, bk_atts, attlist_pen, attlist_misc, attribute flags { flags }?, ## LayerGetDiagramType attribute dia-type { xsd:int }?, attribute link { text }?, attlist_waterfall, attlist_polar, attlist_3d # axes = element axes { attlist_axes, x-axis?, y-axis?, z-axis? } attlist_axes &= empty # x-axis = element x-axis { attlist_axis, text-box } y-axis = element y-axis { attlist_axis, text-box } z-axis = element z-axis { attlist_axis, text-box } ## Diagramgrid attlist_grid = attribute grid-major { xsd:boolean }?, attribute grid-minor { xsd:boolean }?, attribute grid-major-pen-type { xsd:int }?, attribute grid-major-pen-width { xsd:int }?, attribute grid-major-pen-color { color }?, attribute grid-minor-pen-type { xsd:int }?, attribute grid-minor-pen-width { xsd:int }?, attribute grid-minor-pen-color { color }? ## Diagramticks attlist_ticks = ## in cm attribute tick-major-len { xsd:double }?, ## in 0.1mm attribute tick-major-width { xsd:int }?, attribute tick-minor-len { xsd:double }?, attribute tick-minor-width { xsd:int }?, attribute tick-pos { xsd:int }?, attribute tick-minor-count { xsd:int }?, attribute tick-count { xsd:int }? attlist_label_font = attribute label-font-color { color }?, attribute label-font-face-name { text }?, attribute label-font-height { xsd:int }?, # @bug attribute label-font-size { xsd:int }?, attribute label-font-italic { xsd:int }?, attribute label-font-pitch-and-family { xsd:int }?, attribute label-font-strikeout { xsd:int }?, attribute label-font-underline { xsd:int }?, attribute label-font-weight { xsd:int }? attlist_axis = ## LayerGetAxisMinMaxDelta attribute min { xsd:double }?, attribute max { xsd:double }?, attribute delta { xsd:double }?, ## LayerGetAxisLink attribute axis-link { text }?, ## see LayerSetAxisPosition attribute pos { xsd:int }?, ## see LayerSetAxisRelPosition attribute rel-pos { xsd:double }?, ## see LayerSetAutoScale attribute auto-scale { xsd:boolean }?, attribute descending { xsd:boolean }?, ## @bug missing LayerGetAxisPen attlist_ticks, attlist_grid, attlist_label_font, attribute label { xsd:boolean }?, attribute label-format { xsd:int }?, attribute title { xsd:boolean }?, attribute min-line { xsd:boolean }?, attribute max-line { xsd:boolean }?, attribute title-pos { xsd:int }?, attribute title-offset { xsd:double }?, attribute axis-pen-width { xsd:int }? .. relax-end shapes ^^^^^^ .. relax :: shapes = element shapes { attlist_shapes, (group | text-box | table | line | rect | ellipse | image | ole)* } attlist_shapes &= empty group = element group { (group | text-box | table | line | rect | ellipse | image | ole)* } x1y1_x2y2 = attribute x1 { xsd:double }, attribute y1 { xsd:double }, attribute x2 { xsd:double }, attribute y2 { xsd:double } xy_width_height = attribute x { xsd:double }, attribute y { xsd:double }, attribute width { xsd:double }, attribute height { xsd:double }, attribute ref-point { xsd:int }?, attribute diagram-coordinates { xsd:boolean }? flags = list { (xsd:string "no-edit" | xsd:string "no-size" | xsd:string "no-pos" | xsd:string "no-divide" | xsd:string "no-block-edit" | xsd:string "no-axis-edit" | xsd:string "no-print" | xsd:string "no-handle" | xsd:string "hide")+ } ## Das pen-Element hat die Attribute type, width und color (ohne ## stroke-Vorsilbe). attlist_pen = attribute stroke-type { xsd:int }?, attribute stroke-width { xsd:int }?, attribute stroke-color { color }? attlist_misc = attribute shadow { xsd:boolean }?, ## OBJGetShadowWidth 0.1mm attribute shadow-width { xsd:double }?, attribute round-rect { xsd:boolean }?, attribute radius { xsd:double }?, attribute show-edge { xsd:boolean }? .. relax-end line ^^^^ .. relax :: line = element line { attlist_line, maps? } color = xsd:string { pattern = "#[0-9a-fA-F]{6}|[a-z]*" } attlist_line &= attribute name { text }?, x1y1_x2y2, attribute diagram-coordinates { xsd:boolean }?, attlist_pen, attribute start-arrow { xsd:boolean }?, attribute end-arrow { xsd:boolean }?, attribute arrow-lenght { xsd:double }?, attribute arrow-width { xsd:double }?, attribute flags { flags }? .. relax-end text-box ^^^^^^^^ .. relax :: font = element font { attlist_font, empty } attlist_font = attribute face-name { text }?, attribute size { xsd:int }?, attribute weight { xsd:int }?, attribute italic { xsd:boolean }?, attribute underline { xsd:boolean }?, attribute strike-out { xsd:boolean }?, attribute color { color }?, attribute pitch-and-family { xsd:int }? \text = element text { attlist_text, text } attlist_text = empty text-box = element text-box { attlist_text-box, maps?, font?, \text } attlist_text-box = attribute name { text }?, xy_width_height, attlist_pen, attribute flags { flags }?, attlist_misc, bk_atts, ## TBGetAlignHorz attribute halign { "left"|"4"|"center"|"2"|"right"|"1" }?, ## TBGetAlignVert attribute valign { "top"|"8"|"middle"|"16"|"bottom"|"32" }?, ## TBGetAngle attribute angle { xsd:double }?, ## TBGetEdgeDistance in cm attribute edge-dist { xsd:double }?, attribute auto-size { xsd:boolean }?, attribute word-wrap { xsd:boolean }?, attribute clip-text { xsd:boolean }? .. relax-end ellipse ^^^^^^^ .. relax :: ellipse = element ellipse { attlist_ellipse, maps? } attlist_ellipse = attribute name { text }?, xy_width_height, attlist_pen, bk_atts .. relax-end rect ^^^^ .. relax :: rect = element rect { attlist_rect, maps? } attlist_rect = attribute name { text }?, xy_width_height, attlist_pen, attribute flags { flags }?, bk_atts, attribute millimeter-lines { xsd:boolean }? .. relax-end ole ^^^^^^^^^^ .. relax :: ole = element ole { attlist_ole, maps?, ref } attlist_ole = attribute name { text }?, attribute flags { flags }?, xy_width_height ref = element ref { attribute id { string } } .. relax-end image ^^^^^ .. relax :: image = element image { attlist_image, maps?, external-ref } attlist_image = attribute name { text }?, xy_width_height, attribute external-filename { text }?, # attribute link-type { "embedded"|"1"|"linked"|"2"|"both"|"3" }?, attribute link-type { xsd:int }?, attribute frame { xsd:boolean }?, attribute frame-width { xsd:double }?, attribute frame-color { color }? external-ref = element external-ref { attlist_external-ref, empty } attlist_external-ref = attribute ref { string }, attribute ext { text } .. relax-end table ^^^^^ Beispiel einer 2x2-Tabelle: .. image:: S:/uniplot-obj/images/xml-table.* .. code-block:: xml :linenos: A B 1 2
.. relax :: table = element table { attlist_table, maps?, table-resources, table-data } attlist_table = attribute name { text }?, xy_width_height, attribute flags { flags }?, attribute use-placeholder { xsd:boolean }? table-resources = element table-resources { formats, fonts, brushes, pens } formats = element formats { format* } format = element format { attribute type { xsd:int }?, attribute cformat { string }? } fonts = element fonts { font* } brushes = element brushes { brush* } brush = element brush { attribute color {color }, empty } pens = element pens { pen* } pen = element pen { attribute type { xsd:int }?, attribute width { xsd:int }?, attribute color { color }? } table-data = element table-data { merged-cells?, cols, rows } merged-cells = element merged-cells { merged-cell+ } merged-cell = element merged-cell { attribute ref { list { xsd:int, xsd:int, xsd:int, xsd:int} } } cols = element cols { col+ } col = element col { attribute width { xsd:double }, attribute pen-index-bottom { xsd:int }?, empty } rows = element rows { row+ } row = element row { attlist_row, cell+ } attlist_row = attribute height { xsd:double }, attribute pen-index-right { xsd:int }? cell = element cell { attlist_cell, text } attlist_cell = attribute name { text }?, attribute attrib { xsd:int }?, attribute angle { xsd:double }?, attribute align { xsd:int }?, attribute indent-x { xsd:double }?, attribute indent-y { xsd:double }?, attribute font-index { xsd:int }?, attribute brush-index { xsd:int }?, attribute pen-index-horz { xsd:int }?, attribute pen-index-vert { xsd:int }?, attribute format-index { xsd:int }? .. relax-end datasets ^^^^^^^^ .. relax :: datasets = element datasets { attlist_datasets, (xy-dataset | xyz-dataset)* } attlist_datasets &= empty xy-dataset = element xy-dataset { attlist_xy-dataset, xy-dataset-style?, maps?, xy-data-source } attlist_xy-dataset = attribute name { text }?, attribute legend { text }? xy-dataset-style = element xy-dataset-style { attlist_xy-dataset-style } xyz-dataset = element xyz-dataset { attlist_xyz-dataset, xyz-dataset-style?, maps?, xyz-data-source } attlist_xyz-dataset = attribute name { text }?, attribute legend { text }? xyz-dataset-style = element xyz-dataset-style { attlist_xyz-dataset-style } xy-data-source = element data-source { attribute ids { list { string | (string, string) } } } xyz-data-source = element data-source { attribute ids { list { string, string, string } }, attribute type { "matrix" }?, attribute hull-id { string }? } .. relax-end x/y Dataset Attributes """""""""""""""""""""" Curve Attributes """""""""""""""" .. relax :: curveT = list { (xsd:string "solid" | xsd:string "0" | xsd:string "dash" | xsd:string "1" | xsd:string "dot" | xsd:string "2" | xsd:string "dashdot" | xsd:string "3" | xsd:string "dashdotdot" | xsd:string "4" | xsd:string "null" | xsd:string "5") } attlist_curve = attribute curve { xsd:boolean }?, attribute curve-color { color }?, # attribute curve-style { curveT }?, attribute curve-width { xsd:int }? .. relax-end Marker Attributes """"""""""""""""" .. relax :: attlist_marker = attribute marker { xsd:boolean }?, attribute marker-edge-color { color }?, attribute marker-edge-width { xsd:int }?, attribute marker-fill-color { color }?, attribute marker-frequency { xsd:int }?, attribute marker-original { xsd:boolean }?, attribute marker-size { xsd:double }?, attribute marker-style { xsd:int }?, attribute marker-transparent { xsd:boolean }? .. relax-end Bargraph Attributes """"""""""""""""""" .. relax :: attlist_bar = attribute bar { xsd:boolean}?, attribute bar-base-pos { xsd:int }?, attribute bar-fill-color { color }?, attribute bar-hatch-color { color }?, attribute bar-hatch-distance { xsd:double }?, attribute bar-hatch-offset { xsd:double }?, attribute bar-hatch-style { xsd:int }?, attribute bar-hatch-width { xsd:int }?, attribute bar-pen-color { color }?, attribute bar-pen-type { xsd:int }?, attribute bar-pen-width { xsd:int }?, attribute bar-pos { xsd:double }?, attribute bar-type { xsd:int }?, attribute bar-width { xsd:double }?, attribute bar-width-type { xsd:int }?, attribute bar-fill-type { xsd:int }? .. relax-end Fill """" .. relax :: attlist_fill = attribute fill { xsd:boolean }?, attribute fill-color { color }? .. relax-end Hatch """"""""""""""" .. relax :: attlist_hatch = attribute hatch { xsd:boolean }?, attribute hatch-style { xsd:int }?, attribute hatch-width { xsd:double }?, attribute hatch-color { color }?, attribute hatch-distance { xsd:double }?, attribute hatch-offset { xsd:double }? .. relax-end Error Bars """"""""""""""""" .. relax :: attlist_err-bar = attribute err-bar { xsd:boolean }?, attribute err-bar-x-attrib { xsd:int }?, attribute err-bar-x-cap-pen-width { xsd:int }?, attribute err-bar-x-cap-width { xsd:double }?, attribute err-bar-x-pen-color { color }?, attribute err-bar-x-pen-style { xsd:int }?, attribute err-bar-x-pen-width { xsd:int }?, attribute err-bar-x-value { xsd:double }?, attribute err-bar-y-attrib { xsd:int }?, attribute err-bar-y-cap-pen-width { xsd:int }?, attribute err-bar-y-cap-width { xsd:double }?, attribute err-bar-y-pen-color { color }?, attribute err-bar-y-pen-style { xsd:int }?, attribute err-bar-y-pen-width { xsd:int }?, attribute err-bar-y-value { xsd:double }? .. relax-end Drop Pen """"""""""""""""" .. relax :: attlist_drop-pen = attribute drop-pen { xsd:boolean }?, attribute drop-pen-color { color }?, attribute drop-pen-style { xsd:int }?, attribute drop-pen-width { xsd:int }? .. relax-end Filter Functions """"""""""""""""" Siehe :ref:`filter-functions-for-xy-datasets`. .. relax :: attlist_filter-functions = attribute filter-functions { text }?, attribute filter-functions-on { xsd:boolean }? .. relax-end Dataset Attributes """"""""""""""""""""""""" .. relax :: attlist_xy-dataset-style = attribute name { text }?, attribute info-text { text }?, attribute legend-text { text }?, attlist_bar, attlist_curve, attlist_drop-pen, attlist_err-bar, attlist_fill, attlist_hatch, attlist_marker, attlist_filter-functions, attribute x-delta { xsd:double }?, attribute x-start { xsd:double }?, attribute y-base { xsd:double }?, attribute data-scale-x-factor { xsd:double }?, attribute data-scale-x-offset { xsd:double }?, attribute data-scale-y-factor { xsd:double }?, attribute data-scale-y-offset { xsd:double }? .. relax-end x/y/z Dataset Attributes """""""""""""""""""""""" Bubble Plots """"""""""""" .. relax :: attlist_bubble = attribute bubble { xsd:boolean }?, attribute bubble-color-type { xsd:int }?, attribute bubble-size-max { xsd:double }?, attribute bubble-size-min { xsd:double }?, attribute bubble-size-type { xsd:int }?, attribute bubble-scale-min { xsd:double }?, attribute bubble-scale-max { xsd:double }? .. relax-end Marker """"""""""""" .. relax :: attlist_marker_3d = attribute marker { xsd:boolean }?, attribute marker-edge-color { color }?, attribute marker-edge-width { xsd:int }?, attribute marker-fill-color { color }?, attribute marker-label { xsd:boolean }?, attribute marker-label-font-angle { xsd:double }?, attribute marker-label-font-color { color }?, attribute marker-label-font-face-name { text }?, attribute marker-label-font-height { xsd:int }?, attribute marker-label-font-italic { xsd:int }?, attribute marker-label-font-pitch-and-family { xsd:int }?, attribute marker-label-font-strikeout { xsd:int }?, attribute marker-label-font-underline { xsd:int }?, attribute marker-label-font-weight { xsd:int }?, attribute marker-line-index { xsd:boolean }?, attribute marker-size { xsd:double }?, attribute marker-style { xsd:int }?, attribute max-marker { xsd:boolean }?, attribute max-marker-edge-color { color }?, attribute max-marker-edge-width { xsd:int }?, attribute max-marker-fill-color { color }?, attribute max-marker-size { xsd:double }?, attribute max-marker-style { xsd:int }?, attribute min-marker { xsd:boolean }?, attribute min-marker-edge-color { color }?, attribute min-marker-edge-width { xsd:int }?, attribute min-marker-fill-color { color }?, attribute min-marker-size { xsd:double }?, attribute min-marker-style { xsd:int }? .. relax-end Label Font Isoline Labels """"""""""""""""""""""""" .. relax :: label_font = attribute label-font-face-name { text }?, attribute label-font-pitch-and-family { xsd:int }?, attribute label-font-height { xsd:int }?, attribute label-font-weight { xsd:int }?, attribute label-font-italic { xsd:boolean }?, attribute label-font-strikeout { xsd:boolean }?, attribute label-font-underline { xsd:boolean }?, attribute label-font-color { color }?, attribute label-font-angle { xsd:double }? .. relax-end Hull """""" .. relax :: attlist_hull= attribute hull-type { xsd:int }?, attribute hull-label { xsd:boolean }?, attribute hull-label-distance { xsd:double }?, attribute hull-label-horizontal { xsd:boolean }?, attribute hull-pen-color { color }?, attribute hull-pen-style { xsd:int }?, attribute hull-pen-width { xsd:int }?, attribute hull-spline { xsd:boolean }? .. relax-end Interpolation """"""""""""" .. relax :: attlist_interpolation = attribute interpolation-density { text }?, attribute interpolation-on-grid { xsd:boolean }?, attribute interpolation-range { text }?, attribute interpolation-smooth-factor { xsd:int }?, attribute interpolation-type { xsd:int }? .. relax-end Zusammenfassung """"""""""""""" .. relax :: attlist_xyz-dataset-style = attribute base-value-3d { xsd:double }?, attlist_bubble, attlist_hull, attribute filled { xsd:boolean }?, attribute inside-3d-pen-color { color }?, attribute inside-3d-pen-style { xsd:int }?, attribute inside-3d-pen-width { xsd:int }?, attribute inside-color-3d { color }?, attlist_interpolation, attribute iso-colors { text }?, attribute iso-label-type { text }?, attribute iso-min-color { text }?, attribute iso-pen-color { text }?, attribute iso-pen-styles { text }?, attribute iso-pen-width { text }?, attribute iso-values { text }?, attribute isolines { xsd:boolean }?, attribute isolines-3d { xsd:boolean }?, label_font, attribute label-format { text }?, attribute label-in-a-box { xsd:boolean }?, attribute label-in-line-color { xsd:int }?, attribute label-orientation { xsd:int }?, attlist_marker_3d, attribute name { text }?, attribute outside-3d-pen-color { color }?, attribute outside-3d-pen-style { xsd:int }?, attribute outside-3d-pen-width { xsd:int }?, attribute outside-color { color }?, attribute outside-hull-3d-type { xsd:int }?, attribute scatter-bar-width { xsd:double }?, attribute scatter-label-offset-x { xsd:double }?, attribute scatter-label-offset-y { xsd:double }?, attribute spline { xsd:boolean }?, attribute surface-attributes { xsd:int }?, attribute surface-type { xsd:int }?, attribute triangulation { xsd:boolean }? .. relax-end maps ^^^^ Beispiel (Map in einem ``xy-dataset``): .. code-block:: xml :linenos: 0 Comp. 1D 1 0 D:\shiller_Data.xls.nc2 41421.357407407406 1709 1709 1709 0 D:\shiller.xls [Data] 0 0 1709 0 Comp. P .. relax :: maps = element maps { map+ } map = element map { attribute name { text }, obj } .. relax-end .. relax :: obj = element obj { obj_attlist, (obj_inner | simple)* } obj_attlist = attribute id { xsd:positiveInteger }? simple = number | \string | complex | number-matrix | string-matrix | complex-matrix | variant-matrix obj_inner = element obj { obj_inner_attlist, simple* } obj_inner_attlist = key_or_ikey, attribute id { xsd:positiveInteger }?, attribute ref { xsd:positiveInteger }? # number = element number { key_or_ikey, xsd:double } \string = element string { string_attlist, text } string_attlist = key_or_ikey, attribute encoding { xsd:string "base64" }? complex = element complex { key_or_ikey, cpx } # mat_number = element number { xsd:double } mat_string = element string { mat_string_attlist, text } mat_string_attlist = attribute encoding { xsd:string "base64" }? mat_complex = element complex { cpx } # number-matrix = element number-matrix { matrix_attlist, mat_number+ } string-matrix = element string-matrix { matrix_attlist, mat_string+ } complex-matrix = element complex-matrix { matrix_attlist, mat_complex+ } variant-matrix = element variant-matrix { matrix_attlist, (mat_number | mat_string | mat_complex)+ } cpx = xsd:string { pattern = "[\-+]?[0-9]*\.?[0-9]+([eE][\-+]?[0-9]+)?[\-+][0-9]*\.?[0-9]+([eE][\-+]?[0-9]+)?i" } key_or_ikey = attribute key { text } | attribute ikey { xsd:double } row_cols = attribute rows { xsd:positiveInteger }, attribute cols { xsd:positiveInteger } matrix_attlist = key_or_ikey, row_cols .. relax-end Referenzen ---------- [RNG-TUT] http://relaxng.org/compact-tutorial-20030326.html :sub:`id-413190`