23 #ifndef _LAX_SOMEDATA_H
24 #define _LAX_SOMEDATA_H
26 #include <lax/anobject.h>
27 #include <lax/doublebbox.h>
28 #include <lax/vectors.h>
29 #include <lax/lists.h>
30 #include <lax/attributes.h>
32 #include <lax/laximages.h>
33 #include <lax/transformmath.h>
44 namespace LaxInterfaces {
46 #define SOMEDATA_KEEP_ASPECT (1<<0)
47 #define SOMEDATA_KEEP_1_TO_1 (1<<1)
48 #define SOMEDATA_LOCK_SHEAR (1<<2)
49 #define SOMEDATA_LOCK_ROTATION (1<<3)
50 #define SOMEDATA_LOCK_SCALEX (1<<4)
51 #define SOMEDATA_LOCK_SCALEY (1<<5)
52 #define SOMEDATA_LOCK_POSITION (1<<6)
54 #define SOMEDATA_LOCK_CONTENTS (1<<7)
56 #define SOMEDATA_LOCK_KIDS (1<<8)
57 #define SOMEDATA_UNSELECTABLE (1<<9)
58 #define SOMEDATA_UNEDITABLE (1<<10)
75 virtual void touchContents();
78 virtual void GeneratePreview(
int w,
int h);
79 virtual int renderToBuffer(
unsigned char *buffer,
int bufw,
int bufh,
int bufstride,
int bufdepth,
int bufchannels);
87 virtual const char *Id();
88 virtual const char *Id(
const char *newid);
91 SomeData(
double nminx,
double nmaxx,
double nminy,
double nmaxy);
93 virtual const char *whattype() {
return "SomeData"; }
96 virtual flatpoint BBoxPoint(
double x,
double y,
bool transform_to_parent);
97 virtual flatpoint ReferencePoint(
int which,
bool transform_to_parent);
99 virtual int pointin(
flatpoint pp,
int pin=1);
100 virtual int fitto(
double *boxm,DoubleBBox *box,
double alignx,
double aligny,
int whentoscale=2);
101 virtual SomeData *GetParent() {
return NULL; }
103 virtual void dump_out(FILE *f,
int indent,
int what,
Laxkit::anObject *context);
Mon Feb 17 2014 11:52:57, Laxkit