Drawing graphs.

Version :
12.03.2024, 15:56 Uhr

Drawing graphs.

static int draw(ItemRef frame, char* graph_path)

Replace the contents of a frame with a graph. The graph is defined in a XML file. If the representation contains support points, these must be manually deleted prior to the new creation of the graph. The folllowing working method is suggested :

  1. Select frame
  2. Reverse grouping
  3. Select all frames made available
  4. Remove the frames with the graphs from the selection
  5. Delete frames
The command is until now only implemented as a test.

Name Type Default Description
Return int   0 or ErrorCode
frame ItemRef - Target frame, in which the graph is to be inserted.
graph_path String or char* - XML file with the description of the graph. ?
#include "internal/types.h"

Set up the a new frame and draw a graph in this frame. The description of the graph can be found hier.

#include "internal/types.h"
int main () { ItemRef frame = item::alloc (); int result; float l, t, r, b;
result = frame::create (   frame,   kRectangle,   100.0, 210.0, 300.0, 400.0,   1 // Seite   ); if (result) { showmessage ("Rahmen anlegen : %s", serror (result)); item::release (frame); return 0; }
result = graph::draw (frame, "/Users/paul/Desktop/graph1.xml"); if (result) { showmessage ("Graphen zeichnen: %s", serror (result)); item::release (frame); return 0; }
item::release (frame); return 0; }

Matthias [Paul]
Version1.2, February 2005

priint:comet InDesign® Plug-Ins

Author
Paul Seidel
Version
12.03.2024, 15:56 Uhr
Since
Plugin Version 1.1.17

Alphabetic index HTML hierarchy of classes or Java