struct
Tessell::Kit::PaintCmd
- Tessell::Kit::PaintCmd
- Struct
- Value
- Object
Defined in:
tessell/kit/painter.crConstructors
Instance Method Summary
-
#clip : Rect | Nil
命令生效时的裁切矩形(push_clip/pop_clip 交集结果),与 DrawListPainter 的 DrawCmd#clip 同语义(issue #25)。nil = 无裁切。
- #color : UInt32
-
#font_id : Int32
字体 face 维度(issue #29):0 = 默认 face;多 face 栈按宿主 renderer 表选取。与 DrawListPainter 写入 DrawCmd#atlas_id 的语义一致。
- #font_size : Float32
- #kind : PaintKind
- #radius : Float32
- #rect : Rect
- #text : String
-
#texture_id : Int32
外部纹理 handle(issue #28):仅 Image 使用,0 = 未绑定。
- #width : Float32
- #x : Float32
- #x2 : Float32
- #y : Float32
- #y2 : Float32
Constructor Detail
def self.new(kind : PaintKind, rect : Rect = Rect.new, color : UInt32 = 0_u32, width : Float32 = 0.0_f32, radius : Float32 = 0.0_f32, text : String = "", x : Float32 = 0.0_f32, y : Float32 = 0.0_f32, font_size : Float32 = 0.0_f32, x2 : Float32 = 0.0_f32, y2 : Float32 = 0.0_f32, clip : Rect | Nil = nil, font_id : Int32 = 0, texture_id : Int32 = 0)
#
Instance Method Detail
命令生效时的裁切矩形(push_clip/pop_clip 交集结果),与 DrawListPainter 的 DrawCmd#clip 同语义(issue #25)。nil = 无裁切。
def font_id : Int32
#
字体 face 维度(issue #29):0 = 默认 face;多 face 栈按宿主 renderer 表选取。与 DrawListPainter 写入 DrawCmd#atlas_id 的语义一致。