%% %% %CopyrightBegin% %% %% Copyright Ericsson AB 2008-2012. All Rights Reserved. %% %% The contents of this file are subject to the Erlang Public License, %% Version 1.1, (the "License"); you may not use this file except in %% compliance with the License. You should have received a copy of the %% Erlang Public License along with this software. If not, it can be %% retrieved online at http://www.erlang.org/. %% %% Software distributed under the License is distributed on an "AS IS" %% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See %% the License for the specific language governing rights and limitations %% under the License. %% %% %CopyrightEnd% %% This file is generated DO NOT EDIT %% @doc See external documentation: wxGraphicsContext. %%

This class is derived (and can use functions) from: %%
{@link wxGraphicsObject} %%

%% @type wxGraphicsContext(). An object reference, The representation is internal %% and can be changed without notice. It can't be used for comparsion %% stored on disc or distributed for use on other nodes. -module(wxGraphicsContext). -include("wxe.hrl"). -export([clip/2,clip/5,concatTransform/2,create/0,create/1,createBrush/2,createFont/2, createFont/3,createLinearGradientBrush/7,createMatrix/1,createMatrix/2, createPath/1,createPen/2,createRadialGradientBrush/8,destroy/1,drawBitmap/6, drawEllipse/5,drawIcon/6,drawLines/2,drawLines/3,drawPath/2,drawPath/3, drawRectangle/5,drawRoundedRectangle/6,drawText/4,drawText/5,drawText/6, fillPath/2,fillPath/3,getPartialTextExtents/2,getTextExtent/2,getTransform/1, resetClip/1,rotate/2,scale/3,setBrush/2,setFont/2,setFont/3,setPen/2, setTransform/2,strokeLine/5,strokeLines/2,strokePath/2,translate/3]). %% inherited exports -export([getRenderer/1,isNull/1,parent_class/1]). -export_type([wxGraphicsContext/0]). -deprecated([createLinearGradientBrush/7,createRadialGradientBrush/8]). %% @hidden parent_class(wxGraphicsObject) -> true; parent_class(_Class) -> erlang:error({badtype, ?MODULE}). -type wxGraphicsContext() :: wx:wx_object(). %% @doc See external documentation. -spec create() -> wxGraphicsContext(). create() -> wxe_util:call(?wxGraphicsContext_Create_0, <<>>). %% @doc See external documentation. -spec create(Dc) -> wxGraphicsContext() when Dc::wxWindowDC:wxWindowDC() | wxWindow:wxWindow(). create(#wx_ref{type=DcT,ref=DcRef}) -> DcOP = case ?CLASS_T(DcT,wxWindowDC) of true -> ?wxGraphicsContext_Create_1_1; _ -> ?CLASS(DcT,wxWindow), ?wxGraphicsContext_Create_1_0 end, wxe_util:call(DcOP, <>). %% @doc See external documentation. -spec createPen(This, Pen) -> wxGraphicsPen:wxGraphicsPen() when This::wxGraphicsContext(), Pen::wxPen:wxPen(). createPen(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=PenT,ref=PenRef}) -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(PenT,wxPen), wxe_util:call(?wxGraphicsContext_CreatePen, <>). %% @doc See external documentation. -spec createBrush(This, Brush) -> wxGraphicsBrush:wxGraphicsBrush() when This::wxGraphicsContext(), Brush::wxBrush:wxBrush(). createBrush(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=BrushT,ref=BrushRef}) -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(BrushT,wxBrush), wxe_util:call(?wxGraphicsContext_CreateBrush, <>). %% @doc See external documentation. -spec createRadialGradientBrush(This, Xo, Yo, Xc, Yc, Radius, OColor, CColor) -> wxGraphicsBrush:wxGraphicsBrush() when This::wxGraphicsContext(), Xo::number(), Yo::number(), Xc::number(), Yc::number(), Radius::number(), OColor::wx:wx_colour(), CColor::wx:wx_colour(). createRadialGradientBrush(#wx_ref{type=ThisT,ref=ThisRef},Xo,Yo,Xc,Yc,Radius,OColor,CColor) when is_number(Xo),is_number(Yo),is_number(Xc),is_number(Yc),is_number(Radius),tuple_size(OColor) =:= 3; tuple_size(OColor) =:= 4,tuple_size(CColor) =:= 3; tuple_size(CColor) =:= 4 -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:call(?wxGraphicsContext_CreateRadialGradientBrush, <>). %% @doc See external documentation. -spec createLinearGradientBrush(This, X1, Y1, X2, Y2, C1, C2) -> wxGraphicsBrush:wxGraphicsBrush() when This::wxGraphicsContext(), X1::number(), Y1::number(), X2::number(), Y2::number(), C1::wx:wx_colour(), C2::wx:wx_colour(). createLinearGradientBrush(#wx_ref{type=ThisT,ref=ThisRef},X1,Y1,X2,Y2,C1,C2) when is_number(X1),is_number(Y1),is_number(X2),is_number(Y2),tuple_size(C1) =:= 3; tuple_size(C1) =:= 4,tuple_size(C2) =:= 3; tuple_size(C2) =:= 4 -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:call(?wxGraphicsContext_CreateLinearGradientBrush, <>). %% @equiv createFont(This,Font, []) -spec createFont(This, Font) -> wxGraphicsFont:wxGraphicsFont() when This::wxGraphicsContext(), Font::wxFont:wxFont(). createFont(This,Font) when is_record(This, wx_ref),is_record(Font, wx_ref) -> createFont(This,Font, []). %% @doc See external documentation. -spec createFont(This, Font, [Option]) -> wxGraphicsFont:wxGraphicsFont() when This::wxGraphicsContext(), Font::wxFont:wxFont(), Option :: {col, wx:wx_colour()}. createFont(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=FontT,ref=FontRef}, Options) when is_list(Options) -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(FontT,wxFont), MOpts = fun({col, Col}, Acc) -> [<<1:32/?UI,(wxe_util:colour_bin(Col)):16/binary,0:32>>|Acc]; (BadOpt, _) -> erlang:error({badoption, BadOpt}) end, BinOpt = list_to_binary(lists:foldl(MOpts, [<<0:32>>], Options)), wxe_util:call(?wxGraphicsContext_CreateFont, <>). %% @equiv createMatrix(This, []) -spec createMatrix(This) -> wxGraphicsMatrix:wxGraphicsMatrix() when This::wxGraphicsContext(). createMatrix(This) when is_record(This, wx_ref) -> createMatrix(This, []). %% @doc See external documentation. -spec createMatrix(This, [Option]) -> wxGraphicsMatrix:wxGraphicsMatrix() when This::wxGraphicsContext(), Option :: {a, number()} | {b, number()} | {c, number()} | {d, number()} | {tx, number()} | {ty, number()}. createMatrix(#wx_ref{type=ThisT,ref=ThisRef}, Options) when is_list(Options) -> ?CLASS(ThisT,wxGraphicsContext), MOpts = fun({a, A}, Acc) -> [<<1:32/?UI,0:32,A:64/?F>>|Acc]; ({b, B}, Acc) -> [<<2:32/?UI,0:32,B:64/?F>>|Acc]; ({c, C}, Acc) -> [<<3:32/?UI,0:32,C:64/?F>>|Acc]; ({d, D}, Acc) -> [<<4:32/?UI,0:32,D:64/?F>>|Acc]; ({tx, Tx}, Acc) -> [<<5:32/?UI,0:32,Tx:64/?F>>|Acc]; ({ty, Ty}, Acc) -> [<<6:32/?UI,0:32,Ty:64/?F>>|Acc]; (BadOpt, _) -> erlang:error({badoption, BadOpt}) end, BinOpt = list_to_binary(lists:foldl(MOpts, [<<0:32>>], Options)), wxe_util:call(?wxGraphicsContext_CreateMatrix, <>). %% @doc See external documentation. -spec createPath(This) -> wxGraphicsPath:wxGraphicsPath() when This::wxGraphicsContext(). createPath(#wx_ref{type=ThisT,ref=ThisRef}) -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:call(?wxGraphicsContext_CreatePath, <>). %% @doc See external documentation. -spec clip(This, Region) -> ok when This::wxGraphicsContext(), Region::wxRegion:wxRegion(). clip(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=RegionT,ref=RegionRef}) -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(RegionT,wxRegion), wxe_util:cast(?wxGraphicsContext_Clip_1, <>). %% @doc See external documentation. -spec clip(This, X, Y, W, H) -> ok when This::wxGraphicsContext(), X::number(), Y::number(), W::number(), H::number(). clip(#wx_ref{type=ThisT,ref=ThisRef},X,Y,W,H) when is_number(X),is_number(Y),is_number(W),is_number(H) -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:cast(?wxGraphicsContext_Clip_4, <>). %% @doc See external documentation. -spec resetClip(This) -> ok when This::wxGraphicsContext(). resetClip(#wx_ref{type=ThisT,ref=ThisRef}) -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:cast(?wxGraphicsContext_ResetClip, <>). %% @doc See external documentation. -spec drawBitmap(This, Bmp, X, Y, W, H) -> ok when This::wxGraphicsContext(), Bmp::wxBitmap:wxBitmap(), X::number(), Y::number(), W::number(), H::number(). drawBitmap(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=BmpT,ref=BmpRef},X,Y,W,H) when is_number(X),is_number(Y),is_number(W),is_number(H) -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(BmpT,wxBitmap), wxe_util:cast(?wxGraphicsContext_DrawBitmap, <>). %% @doc See external documentation. -spec drawEllipse(This, X, Y, W, H) -> ok when This::wxGraphicsContext(), X::number(), Y::number(), W::number(), H::number(). drawEllipse(#wx_ref{type=ThisT,ref=ThisRef},X,Y,W,H) when is_number(X),is_number(Y),is_number(W),is_number(H) -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:cast(?wxGraphicsContext_DrawEllipse, <>). %% @doc See external documentation. -spec drawIcon(This, Icon, X, Y, W, H) -> ok when This::wxGraphicsContext(), Icon::wxIcon:wxIcon(), X::number(), Y::number(), W::number(), H::number(). drawIcon(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=IconT,ref=IconRef},X,Y,W,H) when is_number(X),is_number(Y),is_number(W),is_number(H) -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(IconT,wxIcon), wxe_util:cast(?wxGraphicsContext_DrawIcon, <>). %% @equiv drawLines(This,Points, []) -spec drawLines(This, Points) -> ok when This::wxGraphicsContext(), Points::[{X::float(), Y::float()}]. drawLines(This,Points) when is_record(This, wx_ref),is_list(Points) -> drawLines(This,Points, []). %% @doc See external documentation. -spec drawLines(This, Points, [Option]) -> ok when This::wxGraphicsContext(), Points::[{X::float(), Y::float()}], Option :: {fillStyle, integer()}. drawLines(#wx_ref{type=ThisT,ref=ThisRef},Points, Options) when is_list(Points),is_list(Options) -> ?CLASS(ThisT,wxGraphicsContext), MOpts = fun({fillStyle, FillStyle}, Acc) -> [<<1:32/?UI,FillStyle:32/?UI>>|Acc]; (BadOpt, _) -> erlang:error({badoption, BadOpt}) end, BinOpt = list_to_binary(lists:foldl(MOpts, [<<0:32>>], Options)), wxe_util:cast(?wxGraphicsContext_DrawLines, <> || {X,Y} <- Points>>)/binary, BinOpt/binary>>). %% @equiv drawPath(This,Path, []) -spec drawPath(This, Path) -> ok when This::wxGraphicsContext(), Path::wxGraphicsPath:wxGraphicsPath(). drawPath(This,Path) when is_record(This, wx_ref),is_record(Path, wx_ref) -> drawPath(This,Path, []). %% @doc See external documentation. -spec drawPath(This, Path, [Option]) -> ok when This::wxGraphicsContext(), Path::wxGraphicsPath:wxGraphicsPath(), Option :: {fillStyle, integer()}. drawPath(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=PathT,ref=PathRef}, Options) when is_list(Options) -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(PathT,wxGraphicsPath), MOpts = fun({fillStyle, FillStyle}, Acc) -> [<<1:32/?UI,FillStyle:32/?UI>>|Acc]; (BadOpt, _) -> erlang:error({badoption, BadOpt}) end, BinOpt = list_to_binary(lists:foldl(MOpts, [<<0:32>>], Options)), wxe_util:cast(?wxGraphicsContext_DrawPath, <>). %% @doc See external documentation. -spec drawRectangle(This, X, Y, W, H) -> ok when This::wxGraphicsContext(), X::number(), Y::number(), W::number(), H::number(). drawRectangle(#wx_ref{type=ThisT,ref=ThisRef},X,Y,W,H) when is_number(X),is_number(Y),is_number(W),is_number(H) -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:cast(?wxGraphicsContext_DrawRectangle, <>). %% @doc See external documentation. -spec drawRoundedRectangle(This, X, Y, W, H, Radius) -> ok when This::wxGraphicsContext(), X::number(), Y::number(), W::number(), H::number(), Radius::number(). drawRoundedRectangle(#wx_ref{type=ThisT,ref=ThisRef},X,Y,W,H,Radius) when is_number(X),is_number(Y),is_number(W),is_number(H),is_number(Radius) -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:cast(?wxGraphicsContext_DrawRoundedRectangle, <>). %% @doc See external documentation. -spec drawText(This, Str, X, Y) -> ok when This::wxGraphicsContext(), Str::unicode:chardata(), X::number(), Y::number(). drawText(#wx_ref{type=ThisT,ref=ThisRef},Str,X,Y) when is_list(Str),is_number(X),is_number(Y) -> ?CLASS(ThisT,wxGraphicsContext), Str_UC = unicode:characters_to_binary([Str,0]), wxe_util:cast(?wxGraphicsContext_DrawText_3, <>). %% @doc See external documentation. %%
Also:
%% drawText(This, Str, X, Y, BackgroundBrush) -> ok when
%% This::wxGraphicsContext(), Str::unicode:chardata(), X::number(), Y::number(), BackgroundBrush::wxGraphicsBrush:wxGraphicsBrush().
%% -spec drawText(This, Str, X, Y, Angle) -> ok when This::wxGraphicsContext(), Str::unicode:chardata(), X::number(), Y::number(), Angle::number(); (This, Str, X, Y, BackgroundBrush) -> ok when This::wxGraphicsContext(), Str::unicode:chardata(), X::number(), Y::number(), BackgroundBrush::wxGraphicsBrush:wxGraphicsBrush(). drawText(#wx_ref{type=ThisT,ref=ThisRef},Str,X,Y,Angle) when is_list(Str),is_number(X),is_number(Y),is_number(Angle) -> ?CLASS(ThisT,wxGraphicsContext), Str_UC = unicode:characters_to_binary([Str,0]), wxe_util:cast(?wxGraphicsContext_DrawText_4_0, <>); drawText(#wx_ref{type=ThisT,ref=ThisRef},Str,X,Y,#wx_ref{type=BackgroundBrushT,ref=BackgroundBrushRef}) when is_list(Str),is_number(X),is_number(Y) -> ?CLASS(ThisT,wxGraphicsContext), Str_UC = unicode:characters_to_binary([Str,0]), ?CLASS(BackgroundBrushT,wxGraphicsBrush), wxe_util:cast(?wxGraphicsContext_DrawText_4_1, <>). %% @doc See external documentation. -spec drawText(This, Str, X, Y, Angle, BackgroundBrush) -> ok when This::wxGraphicsContext(), Str::unicode:chardata(), X::number(), Y::number(), Angle::number(), BackgroundBrush::wxGraphicsBrush:wxGraphicsBrush(). drawText(#wx_ref{type=ThisT,ref=ThisRef},Str,X,Y,Angle,#wx_ref{type=BackgroundBrushT,ref=BackgroundBrushRef}) when is_list(Str),is_number(X),is_number(Y),is_number(Angle) -> ?CLASS(ThisT,wxGraphicsContext), Str_UC = unicode:characters_to_binary([Str,0]), ?CLASS(BackgroundBrushT,wxGraphicsBrush), wxe_util:cast(?wxGraphicsContext_DrawText_5, <>). %% @equiv fillPath(This,Path, []) -spec fillPath(This, Path) -> ok when This::wxGraphicsContext(), Path::wxGraphicsPath:wxGraphicsPath(). fillPath(This,Path) when is_record(This, wx_ref),is_record(Path, wx_ref) -> fillPath(This,Path, []). %% @doc See external documentation. -spec fillPath(This, Path, [Option]) -> ok when This::wxGraphicsContext(), Path::wxGraphicsPath:wxGraphicsPath(), Option :: {fillStyle, integer()}. fillPath(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=PathT,ref=PathRef}, Options) when is_list(Options) -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(PathT,wxGraphicsPath), MOpts = fun({fillStyle, FillStyle}, Acc) -> [<<1:32/?UI,FillStyle:32/?UI>>|Acc]; (BadOpt, _) -> erlang:error({badoption, BadOpt}) end, BinOpt = list_to_binary(lists:foldl(MOpts, [<<0:32>>], Options)), wxe_util:cast(?wxGraphicsContext_FillPath, <>). %% @doc See external documentation. -spec strokePath(This, Path) -> ok when This::wxGraphicsContext(), Path::wxGraphicsPath:wxGraphicsPath(). strokePath(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=PathT,ref=PathRef}) -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(PathT,wxGraphicsPath), wxe_util:cast(?wxGraphicsContext_StrokePath, <>). %% @doc See external documentation. -spec getPartialTextExtents(This, Text) -> [number()] when This::wxGraphicsContext(), Text::unicode:chardata(). getPartialTextExtents(#wx_ref{type=ThisT,ref=ThisRef},Text) when is_list(Text) -> ?CLASS(ThisT,wxGraphicsContext), Text_UC = unicode:characters_to_binary([Text,0]), wxe_util:call(?wxGraphicsContext_GetPartialTextExtents, <>). %% @doc See external documentation. -spec getTextExtent(This, Text) -> Result when Result ::{Width::number(), Height::number(), Descent::number(), ExternalLeading::number()}, This::wxGraphicsContext(), Text::unicode:chardata(). getTextExtent(#wx_ref{type=ThisT,ref=ThisRef},Text) when is_list(Text) -> ?CLASS(ThisT,wxGraphicsContext), Text_UC = unicode:characters_to_binary([Text,0]), wxe_util:call(?wxGraphicsContext_GetTextExtent, <>). %% @doc See external documentation. -spec rotate(This, Angle) -> ok when This::wxGraphicsContext(), Angle::number(). rotate(#wx_ref{type=ThisT,ref=ThisRef},Angle) when is_number(Angle) -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:cast(?wxGraphicsContext_Rotate, <>). %% @doc See external documentation. -spec scale(This, XScale, YScale) -> ok when This::wxGraphicsContext(), XScale::number(), YScale::number(). scale(#wx_ref{type=ThisT,ref=ThisRef},XScale,YScale) when is_number(XScale),is_number(YScale) -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:cast(?wxGraphicsContext_Scale, <>). %% @doc See external documentation. -spec translate(This, Dx, Dy) -> ok when This::wxGraphicsContext(), Dx::number(), Dy::number(). translate(#wx_ref{type=ThisT,ref=ThisRef},Dx,Dy) when is_number(Dx),is_number(Dy) -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:cast(?wxGraphicsContext_Translate, <>). %% @doc See external documentation. -spec getTransform(This) -> wxGraphicsMatrix:wxGraphicsMatrix() when This::wxGraphicsContext(). getTransform(#wx_ref{type=ThisT,ref=ThisRef}) -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:call(?wxGraphicsContext_GetTransform, <>). %% @doc See external documentation. -spec setTransform(This, Matrix) -> ok when This::wxGraphicsContext(), Matrix::wxGraphicsMatrix:wxGraphicsMatrix(). setTransform(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=MatrixT,ref=MatrixRef}) -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(MatrixT,wxGraphicsMatrix), wxe_util:cast(?wxGraphicsContext_SetTransform, <>). %% @doc See external documentation. -spec concatTransform(This, Matrix) -> ok when This::wxGraphicsContext(), Matrix::wxGraphicsMatrix:wxGraphicsMatrix(). concatTransform(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=MatrixT,ref=MatrixRef}) -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(MatrixT,wxGraphicsMatrix), wxe_util:cast(?wxGraphicsContext_ConcatTransform, <>). %% @doc See external documentation. -spec setBrush(This, Brush) -> ok when This::wxGraphicsContext(), Brush::wxGraphicsBrush:wxGraphicsBrush() | wxBrush:wxBrush(). setBrush(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=BrushT,ref=BrushRef}) -> ?CLASS(ThisT,wxGraphicsContext), BrushOP = case ?CLASS_T(BrushT,wxGraphicsBrush) of true -> ?wxGraphicsContext_SetBrush_1_1; _ -> ?CLASS(BrushT,wxBrush), ?wxGraphicsContext_SetBrush_1_0 end, wxe_util:cast(BrushOP, <>). %% @doc See external documentation. -spec setFont(This, Font) -> ok when This::wxGraphicsContext(), Font::wxGraphicsFont:wxGraphicsFont(). setFont(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=FontT,ref=FontRef}) -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(FontT,wxGraphicsFont), wxe_util:cast(?wxGraphicsContext_SetFont_1, <>). %% @doc See external documentation. -spec setFont(This, Font, Colour) -> ok when This::wxGraphicsContext(), Font::wxFont:wxFont(), Colour::wx:wx_colour(). setFont(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=FontT,ref=FontRef},Colour) when tuple_size(Colour) =:= 3; tuple_size(Colour) =:= 4 -> ?CLASS(ThisT,wxGraphicsContext), ?CLASS(FontT,wxFont), wxe_util:cast(?wxGraphicsContext_SetFont_2, <>). %% @doc See external documentation. -spec setPen(This, Pen) -> ok when This::wxGraphicsContext(), Pen::wxPen:wxPen() | wxGraphicsPen:wxGraphicsPen(). setPen(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=PenT,ref=PenRef}) -> ?CLASS(ThisT,wxGraphicsContext), PenOP = case ?CLASS_T(PenT,wxPen) of true -> ?wxGraphicsContext_SetPen_1_1; _ -> ?CLASS(PenT,wxGraphicsPen), ?wxGraphicsContext_SetPen_1_0 end, wxe_util:cast(PenOP, <>). %% @doc See external documentation. -spec strokeLine(This, X1, Y1, X2, Y2) -> ok when This::wxGraphicsContext(), X1::number(), Y1::number(), X2::number(), Y2::number(). strokeLine(#wx_ref{type=ThisT,ref=ThisRef},X1,Y1,X2,Y2) when is_number(X1),is_number(Y1),is_number(X2),is_number(Y2) -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:cast(?wxGraphicsContext_StrokeLine, <>). %% @doc See external documentation. -spec strokeLines(This, Points) -> ok when This::wxGraphicsContext(), Points::[{X::float(), Y::float()}]. strokeLines(#wx_ref{type=ThisT,ref=ThisRef},Points) when is_list(Points) -> ?CLASS(ThisT,wxGraphicsContext), wxe_util:cast(?wxGraphicsContext_StrokeLines, <> || {X,Y} <- Points>>)/binary>>). %% @doc Destroys this object, do not use object again -spec destroy(This::wxGraphicsContext()) -> ok. destroy(Obj=#wx_ref{type=Type}) -> ?CLASS(Type,wxGraphicsContext), wxe_util:destroy(?DESTROY_OBJECT,Obj), ok. %% From wxGraphicsObject %% @hidden isNull(This) -> wxGraphicsObject:isNull(This). %% @hidden getRenderer(This) -> wxGraphicsObject:getRenderer(This).