Documentation
¶
Overview ¶
Package svg 封装了对SVG矢量图形的相关操作.
Index ¶
- type Svg
- func NewByFile(pFileName string) *Svg
- func NewByRes(id int32, pType string, hModule uintptr) *Svg
- func NewByString(pString string) *Svg
- func NewByStringUtf8(pString string) *Svg
- func NewByStringW(pString string) *Svg
- func NewByZip(pZipFileName, pFileName, pPassword string) *Svg
- func NewByZipMem(data []byte, pFileName, pPassword string) *Svg
- func NewByZipRes(id int32, pFileName, pPassword string, hModule uintptr) *Svg
- func (s *Svg) AddRef() *Svg
- func (s *Svg) Destroy() *Svg
- func (s *Svg) EnableAutoDestroy(bEnable bool) *Svg
- func (s *Svg) GetAlpha() byte
- func (s *Svg) GetHeight() int32
- func (s *Svg) GetPosition(pX, pY *int32) *Svg
- func (s *Svg) GetPositionF(pX, pY *float32) *Svg
- func (s *Svg) GetRefCount() int32
- func (s *Svg) GetRotate(pAngle *float32, pX *float32, pY *float32, pbOffset *bool) *Svg
- func (s *Svg) GetRotateAngle() float32
- func (s *Svg) GetSize(pWidth, pHeight *int32) *Svg
- func (s *Svg) GetUserFillColor(pColor *int) bool
- func (s *Svg) GetUserStrokeColor(pColor *int, pStrokeWidth *float32) bool
- func (s *Svg) GetViewBox(pViewBox *xc.RECT) *Svg
- func (s *Svg) GetWidth() int32
- func (s *Svg) Release() *Svg
- func (s *Svg) SetAlpha(alpha byte) *Svg
- func (s *Svg) SetPosition(x, y int32) *Svg
- func (s *Svg) SetPositionF(x, y float32) *Svg
- func (s *Svg) SetRotate(angle float32, x float32, y float32, bOffset bool) *Svg
- func (s *Svg) SetRotateAngle(angle float32) *Svg
- func (s *Svg) SetSize(nWidth, nHeight int32) *Svg
- func (s *Svg) SetUserFillColor(color int, bEnable bool) *Svg
- func (s *Svg) SetUserStrokeColor(color int, strokeWidth float32, bEnable bool) *Svg
- func (s *Svg) Show(bShow bool) *Svg
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Svg ¶
type Svg struct {
objectbase.ObjectBase
}
Svg SVG矢量图形.
func NewByRes ¶ added in v1.3.352
NewByRes SVG_加载从资源, 返回Svg对象.
id: 资源ID.
pType: 资源类型.在rc资源文件中.
hModule: 从指定模块加载.
func NewByZip ¶ added in v1.3.352
NewByZip SVG_加载从ZIP, 返回Svg对象.
pZipFileName: zip文件名.
pFileName: svg文件名.
pPassword: zip密码.
func NewByZipMem ¶ added in v1.3.352
NewByZipMem SVG_加载从内存ZIP, 返回Svg对象.
data: zip数据.
pFileName: svg文件名.
pPassword: zip密码.
func NewByZipRes ¶ added in v1.3.380
NewByZipRes SVG_加载从资源ZIP, 返回SVG对象.
id: 资源ID.
pFileName: svg文件名.
pPassword: zip密码.
hModule: 模块句柄, 可填0.
func (*Svg) GetRotate ¶
SVG_取旋转.
pAngle: 返回角度.
pX: 返回 旋转中心点X.
pY: 返回 旋转中心点Y.
pbOffset: 返回TRUE: 旋转中心点相对于自身中心偏移, FALSE:使用绝对坐标.
func (*Svg) SetRotate ¶
SVG_置旋转.
angle: 角度.
x: 旋转中心点X.
y: 旋转中心点Y.
bOffset: TRUE: 旋转中心点相对于自身中心偏移, FALSE:使用绝对坐标.
func (*Svg) SetUserStrokeColor ¶
SVG_置用户笔触颜色, 用户颜色将覆盖默认样式.
color: xc.RGBA 颜色.
strokeWidth: 笔触宽度.
bEnable: 是否有效.