Package: graphene

Macro graphene:with-sizes

Lambda List

graphene:with-sizes (vars &body body)

Syntax

(graphene:with-sizes (s1 s2 s3 ... sn) body) => result

Arguments

s1 ... sn -- the newly created graphene:size-t instances
body -- a body that uses the bindings s1 ... sn

Details

The graphene:with-sizes macro creates new variable bindings and executes the body that use these bindings. The macro performs the bindings sequentially, like the let* macro.

Each size can be initialized with values using the syntax for the graphene:with-size macro. See also the graphene:with-size documentation.

Examples

(graphene:with-sizes (s1 (s2 1.2 1.3) (s3 s2))
  (list (list (graphene:size-width s1) (graphene:size-height s1))
        (list (graphene:size-width s2) (graphene:size-height s2))
        (list (graphene:size-width s3) (graphene:size-height s3))))
=> ((0.0 0.0) (1.2 1.3) (1.2 1.3))    
 

See also

2024-1-20