# TSV with instructions in first column starting with @

@sect	Concrete objects

@table	line object fields
@anchor	line
@cols	field	type	description
<a href="#common">(common)</a>	&nbsp;	common object fields are available
<a href="#pen">stroke</a>	&nbsp;	pen fields used for object stroke; e.g. .stroke is the stroke pen name, .stroke.color is stroke pen color
x1	coord	start point x coord
y1	coord	start point y coord
x2	coord	end point x coord
y2	coord	end point y coord
length	coord	calculated length
length2	double	square of calculated length (cheaper to calculate)
area	double	"ink quantity": approx. area of the line as rendered [coord<sup>2</sup>]

@table	arc object fields
@anchor	arc
@cols	field	type	description
<a href="#common">(common)</a>	&nbsp;	common object fields are available
<a href="#pen">stroke</a>	&nbsp;	pen fields used for object stroke; e.g. .stroke is the stroke pen name, .stroke.color is stroke pen color
start	double	start angle [degrees]
delta	double	angle span [degrees]
x or cx	coord	arc center x coord
y or cy	coord	arc center y coord
r	coord	arc radius
length	coord	calculated length
length2	double	square of calculated length (cheaper to calculate)
area	double	"ink quantity": approx. area of the arc as rendered [coord<sup>2</sup>]


@table	text object fields
@anchor	text
@cols	field	type	description
<a href="#common">(common)</a>	&nbsp;	common object fields are available
x or x1	coord	placement box bottom left
y or y1	coord	placement box bottom left
x2	coord	placement box top right (also used for determining text height)
y2	coord	placement box top right (also used for determining text height)
rotation	double	in degrees
string	str	text string as specified by the user (may be a dyntext template)
render	str	as rendered currently (with dyntext template executed)
dyntext	int	1 if text is dyntext templated, 0 otherwise
has_bbox	int	1 if text is bbox-specified, 0 if height-specified
halign	int	<a href="#halign">horizontal alignment ID</a>

@table	conn object fields
@anchor	conn
@cols	field	type	description
<a href="#common">(common)</a>	&nbsp;	common object fields are available
conn	list	all objects that are connected by this conn object

@table	polygon object fields
@anchor	polygon
@cols	field	type	description
<a href="#common">(common)</a>	&nbsp;	common object fields are available
<a href="#pen">stroke</a>	&nbsp;	pen fields used for object stroke; e.g. .stroke is the stroke pen name, .stroke.color is stroke pen color
<a href="#pen">fill</a>	&nbsp;	pen fields used for object fill; e.g. .fill is the fill pen name, .fill.color is fill pen color
points	int	number of corners
area	double	"ink quantity": area of the polygon as rendered [coord<sup>2</sup>]

@table	group object fields
@anchor	grp
@cols	field	type	description
<a href="#common">(common)</a>	&nbsp;	common object fields are available
x	coord	origin (placement) coord
y	coord	origin (placement) coord
rotation	double	rotation around origin, in degrees
mirx	int	1 if group is horizontally mirrored, 0 otherwise
miry	int	1 if group is vertically mirrored, 0 otherwise
area	double	bbox area of the group as rendered [coord<sup>2</sup>]


@sect	Common concrete object fields and types

@table	types
@anchor	types
@cols	type ID	type name
1	LINE
2	ARC
3	POLY
4	TEXT
5	BITMAP
6	CONN
7	GRP
8	GRP_REF
9 PEN

@table	horizontal alignment IDs
@anchor	halign
@cols	halign ID	alignment name
0	left
1	center
2	right
3	word justify
4	justify

@table	common fields
@anchor	common
@cols	field	type	description
ID	int	object's <i>oid<i>
level	int	which level of the hierarchy the object is on; level 0 is the direct group of the sheet; level 1 is an object placed on the sheet
bbox.x1	coord	object's bounding box, leftmost X coordinate
bbox.y1	coord	object's bounding box, bottom Y coordinate
bbox.x2	coord	object's bounding box, rightmost X coordinate
bbox.y2	coord	object's bounding box, top Y coordinate
bbox.width	coord	object's bounding box, horizontal size
bbox.height	coord	object's bounding box, vertical size
type	int	<a href="#types">object type ID</a>
selected	int	1 if object is selected, else 0
locked	int	1 if object is explicitly locked (lock tool), else 0
anylocked	int	1 if the object is locked in any way (parent is locked or parent is an atomic group, e.g. symbol and object is not a floater)
floater	int	1 if object is a floater, else 0
parent	obj	object's parent group
displayer	int	display layer ID the object is rendered on
displayer_name	string	display layer name the object is rendered on
conn	list	list of objects the current object is connected to via a conn object

@table	pen fields
@cols	field	type	description
&nbsp;	str	without futher fields appended, evaluates to the name of the pen
shape	str	<i>round</i> or <i>square</i>
is_round	int	1 if shape is <i>round</i>, else 0
size	coord	pen diameter if shape is <i>round</i>, side length if shape is <i>square</i>
color	str	in #rrggbb format
dash	int	dash pattern (see design doc)
dash_period	coord	dash period (see design doc)
font_height	coord	for non-bbox specified text rendered with this pen
font_family	str	hint for font selection
font_style	str	hint for font selection
