1%% 2%% %CopyrightBegin% 3%% 4%% Copyright Ericsson AB 2008-2020. All Rights Reserved. 5%% 6%% Licensed under the Apache License, Version 2.0 (the "License"); 7%% you may not use this file except in compliance with the License. 8%% You may obtain a copy of the License at 9%% 10%% http://www.apache.org/licenses/LICENSE-2.0 11%% 12%% Unless required by applicable law or agreed to in writing, software 13%% distributed under the License is distributed on an "AS IS" BASIS, 14%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15%% See the License for the specific language governing permissions and 16%% limitations under the License. 17%% 18%% %CopyrightEnd% 19%% This file is generated DO NOT EDIT 20 21-module(wxGraphicsPath). 22-include("wxe.hrl"). 23-export([addArc/6,addArc/7,addArcToPoint/6,addCircle/4,addCurveToPoint/4,addCurveToPoint/7, 24 addEllipse/5,addLineToPoint/2,addLineToPoint/3,addPath/2,addQuadCurveToPoint/5, 25 addRectangle/5,addRoundedRectangle/6,closeSubpath/1,contains/2,contains/3, 26 contains/4,getBox/1,getCurrentPoint/1,moveToPoint/2,moveToPoint/3, 27 transform/2]). 28 29%% inherited exports 30-export([getRenderer/1,isNull/1,parent_class/1]). 31 32-type wxGraphicsPath() :: wx:wx_object(). 33-export_type([wxGraphicsPath/0]). 34%% @hidden 35parent_class(wxGraphicsObject) -> true; 36parent_class(_Class) -> erlang:error({badtype, ?MODULE}). 37 38%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathmovetopoint">external documentation</a>. 39-spec moveToPoint(This, P) -> 'ok' when 40 This::wxGraphicsPath(), P::{X::float(), Y::float()}. 41moveToPoint(#wx_ref{type=ThisT}=This,{PX,PY} = P) 42 when is_number(PX),is_number(PY) -> 43 ?CLASS(ThisT,wxGraphicsPath), 44 wxe_util:queue_cmd(This,P,?get_env(),?wxGraphicsPath_MoveToPoint_1). 45 46%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathmovetopoint">external documentation</a>. 47-spec moveToPoint(This, X, Y) -> 'ok' when 48 This::wxGraphicsPath(), X::number(), Y::number(). 49moveToPoint(#wx_ref{type=ThisT}=This,X,Y) 50 when is_number(X),is_number(Y) -> 51 ?CLASS(ThisT,wxGraphicsPath), 52 wxe_util:queue_cmd(This,X,Y,?get_env(),?wxGraphicsPath_MoveToPoint_2). 53 54%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddarc">external documentation</a>. 55-spec addArc(This, C, R, StartAngle, EndAngle, Clockwise) -> 'ok' when 56 This::wxGraphicsPath(), C::{X::float(), Y::float()}, R::number(), StartAngle::number(), EndAngle::number(), Clockwise::boolean(). 57addArc(#wx_ref{type=ThisT}=This,{CX,CY} = C,R,StartAngle,EndAngle,Clockwise) 58 when is_number(CX),is_number(CY),is_number(R),is_number(StartAngle),is_number(EndAngle),is_boolean(Clockwise) -> 59 ?CLASS(ThisT,wxGraphicsPath), 60 wxe_util:queue_cmd(This,C,R,StartAngle,EndAngle,Clockwise,?get_env(),?wxGraphicsPath_AddArc_5). 61 62%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddarc">external documentation</a>. 63-spec addArc(This, X, Y, R, StartAngle, EndAngle, Clockwise) -> 'ok' when 64 This::wxGraphicsPath(), X::number(), Y::number(), R::number(), StartAngle::number(), EndAngle::number(), Clockwise::boolean(). 65addArc(#wx_ref{type=ThisT}=This,X,Y,R,StartAngle,EndAngle,Clockwise) 66 when is_number(X),is_number(Y),is_number(R),is_number(StartAngle),is_number(EndAngle),is_boolean(Clockwise) -> 67 ?CLASS(ThisT,wxGraphicsPath), 68 wxe_util:queue_cmd(This,X,Y,R,StartAngle,EndAngle,Clockwise,?get_env(),?wxGraphicsPath_AddArc_6). 69 70%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddarctopoint">external documentation</a>. 71-spec addArcToPoint(This, X1, Y1, X2, Y2, R) -> 'ok' when 72 This::wxGraphicsPath(), X1::number(), Y1::number(), X2::number(), Y2::number(), R::number(). 73addArcToPoint(#wx_ref{type=ThisT}=This,X1,Y1,X2,Y2,R) 74 when is_number(X1),is_number(Y1),is_number(X2),is_number(Y2),is_number(R) -> 75 ?CLASS(ThisT,wxGraphicsPath), 76 wxe_util:queue_cmd(This,X1,Y1,X2,Y2,R,?get_env(),?wxGraphicsPath_AddArcToPoint). 77 78%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddcircle">external documentation</a>. 79-spec addCircle(This, X, Y, R) -> 'ok' when 80 This::wxGraphicsPath(), X::number(), Y::number(), R::number(). 81addCircle(#wx_ref{type=ThisT}=This,X,Y,R) 82 when is_number(X),is_number(Y),is_number(R) -> 83 ?CLASS(ThisT,wxGraphicsPath), 84 wxe_util:queue_cmd(This,X,Y,R,?get_env(),?wxGraphicsPath_AddCircle). 85 86%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddcurvetopoint">external documentation</a>. 87-spec addCurveToPoint(This, C1, C2, E) -> 'ok' when 88 This::wxGraphicsPath(), C1::{X::float(), Y::float()}, C2::{X::float(), Y::float()}, E::{X::float(), Y::float()}. 89addCurveToPoint(#wx_ref{type=ThisT}=This,{C1X,C1Y} = C1,{C2X,C2Y} = C2,{EX,EY} = E) 90 when is_number(C1X),is_number(C1Y),is_number(C2X),is_number(C2Y),is_number(EX),is_number(EY) -> 91 ?CLASS(ThisT,wxGraphicsPath), 92 wxe_util:queue_cmd(This,C1,C2,E,?get_env(),?wxGraphicsPath_AddCurveToPoint_3). 93 94%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddcurvetopoint">external documentation</a>. 95-spec addCurveToPoint(This, Cx1, Cy1, Cx2, Cy2, X, Y) -> 'ok' when 96 This::wxGraphicsPath(), Cx1::number(), Cy1::number(), Cx2::number(), Cy2::number(), X::number(), Y::number(). 97addCurveToPoint(#wx_ref{type=ThisT}=This,Cx1,Cy1,Cx2,Cy2,X,Y) 98 when is_number(Cx1),is_number(Cy1),is_number(Cx2),is_number(Cy2),is_number(X),is_number(Y) -> 99 ?CLASS(ThisT,wxGraphicsPath), 100 wxe_util:queue_cmd(This,Cx1,Cy1,Cx2,Cy2,X,Y,?get_env(),?wxGraphicsPath_AddCurveToPoint_6). 101 102%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddellipse">external documentation</a>. 103-spec addEllipse(This, X, Y, W, H) -> 'ok' when 104 This::wxGraphicsPath(), X::number(), Y::number(), W::number(), H::number(). 105addEllipse(#wx_ref{type=ThisT}=This,X,Y,W,H) 106 when is_number(X),is_number(Y),is_number(W),is_number(H) -> 107 ?CLASS(ThisT,wxGraphicsPath), 108 wxe_util:queue_cmd(This,X,Y,W,H,?get_env(),?wxGraphicsPath_AddEllipse). 109 110%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddlinetopoint">external documentation</a>. 111-spec addLineToPoint(This, P) -> 'ok' when 112 This::wxGraphicsPath(), P::{X::float(), Y::float()}. 113addLineToPoint(#wx_ref{type=ThisT}=This,{PX,PY} = P) 114 when is_number(PX),is_number(PY) -> 115 ?CLASS(ThisT,wxGraphicsPath), 116 wxe_util:queue_cmd(This,P,?get_env(),?wxGraphicsPath_AddLineToPoint_1). 117 118%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddlinetopoint">external documentation</a>. 119-spec addLineToPoint(This, X, Y) -> 'ok' when 120 This::wxGraphicsPath(), X::number(), Y::number(). 121addLineToPoint(#wx_ref{type=ThisT}=This,X,Y) 122 when is_number(X),is_number(Y) -> 123 ?CLASS(ThisT,wxGraphicsPath), 124 wxe_util:queue_cmd(This,X,Y,?get_env(),?wxGraphicsPath_AddLineToPoint_2). 125 126%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddpath">external documentation</a>. 127-spec addPath(This, Path) -> 'ok' when 128 This::wxGraphicsPath(), Path::wxGraphicsPath(). 129addPath(#wx_ref{type=ThisT}=This,#wx_ref{type=PathT}=Path) -> 130 ?CLASS(ThisT,wxGraphicsPath), 131 ?CLASS(PathT,wxGraphicsPath), 132 wxe_util:queue_cmd(This,Path,?get_env(),?wxGraphicsPath_AddPath). 133 134%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddquadcurvetopoint">external documentation</a>. 135-spec addQuadCurveToPoint(This, Cx, Cy, X, Y) -> 'ok' when 136 This::wxGraphicsPath(), Cx::number(), Cy::number(), X::number(), Y::number(). 137addQuadCurveToPoint(#wx_ref{type=ThisT}=This,Cx,Cy,X,Y) 138 when is_number(Cx),is_number(Cy),is_number(X),is_number(Y) -> 139 ?CLASS(ThisT,wxGraphicsPath), 140 wxe_util:queue_cmd(This,Cx,Cy,X,Y,?get_env(),?wxGraphicsPath_AddQuadCurveToPoint). 141 142%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddrectangle">external documentation</a>. 143-spec addRectangle(This, X, Y, W, H) -> 'ok' when 144 This::wxGraphicsPath(), X::number(), Y::number(), W::number(), H::number(). 145addRectangle(#wx_ref{type=ThisT}=This,X,Y,W,H) 146 when is_number(X),is_number(Y),is_number(W),is_number(H) -> 147 ?CLASS(ThisT,wxGraphicsPath), 148 wxe_util:queue_cmd(This,X,Y,W,H,?get_env(),?wxGraphicsPath_AddRectangle). 149 150%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathaddroundedrectangle">external documentation</a>. 151-spec addRoundedRectangle(This, X, Y, W, H, Radius) -> 'ok' when 152 This::wxGraphicsPath(), X::number(), Y::number(), W::number(), H::number(), Radius::number(). 153addRoundedRectangle(#wx_ref{type=ThisT}=This,X,Y,W,H,Radius) 154 when is_number(X),is_number(Y),is_number(W),is_number(H),is_number(Radius) -> 155 ?CLASS(ThisT,wxGraphicsPath), 156 wxe_util:queue_cmd(This,X,Y,W,H,Radius,?get_env(),?wxGraphicsPath_AddRoundedRectangle). 157 158%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathclosesubpath">external documentation</a>. 159-spec closeSubpath(This) -> 'ok' when 160 This::wxGraphicsPath(). 161closeSubpath(#wx_ref{type=ThisT}=This) -> 162 ?CLASS(ThisT,wxGraphicsPath), 163 wxe_util:queue_cmd(This,?get_env(),?wxGraphicsPath_CloseSubpath). 164 165%% @equiv contains(This,C, []) 166-spec contains(This, C) -> boolean() when 167 This::wxGraphicsPath(), C::{X::float(), Y::float()}. 168 169contains(This,{CX,CY} = C) 170 when is_record(This, wx_ref),is_number(CX),is_number(CY) -> 171 contains(This,C, []). 172 173%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathcontains">external documentation</a>. 174%% <br /> Also:<br /> 175%% contains(This, C, [Option]) -> boolean() when<br /> 176%% This::wxGraphicsPath(), C::{X::float(), Y::float()},<br /> 177%% Option :: {'fillStyle', wx:wx_enum()}.<br /> 178%% 179%%<br /> FillStyle = ?wxODDEVEN_RULE | ?wxWINDING_RULE 180-spec contains(This, X, Y) -> boolean() when 181 This::wxGraphicsPath(), X::number(), Y::number(); 182 (This, C, [Option]) -> boolean() when 183 This::wxGraphicsPath(), C::{X::float(), Y::float()}, 184 Option :: {'fillStyle', wx:wx_enum()}. 185 186contains(This,X,Y) 187 when is_record(This, wx_ref),is_number(X),is_number(Y) -> 188 contains(This,X,Y, []); 189contains(#wx_ref{type=ThisT}=This,{CX,CY} = C, Options) 190 when is_number(CX),is_number(CY),is_list(Options) -> 191 ?CLASS(ThisT,wxGraphicsPath), 192 MOpts = fun({fillStyle, _fillStyle} = Arg) -> Arg; 193 (BadOpt) -> erlang:error({badoption, BadOpt}) end, 194 Opts = lists:map(MOpts, Options), 195 wxe_util:queue_cmd(This,C, Opts,?get_env(),?wxGraphicsPath_Contains_2), 196 wxe_util:rec(?wxGraphicsPath_Contains_2). 197 198%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathcontains">external documentation</a>. 199%%<br /> FillStyle = ?wxODDEVEN_RULE | ?wxWINDING_RULE 200-spec contains(This, X, Y, [Option]) -> boolean() when 201 This::wxGraphicsPath(), X::number(), Y::number(), 202 Option :: {'fillStyle', wx:wx_enum()}. 203contains(#wx_ref{type=ThisT}=This,X,Y, Options) 204 when is_number(X),is_number(Y),is_list(Options) -> 205 ?CLASS(ThisT,wxGraphicsPath), 206 MOpts = fun({fillStyle, _fillStyle} = Arg) -> Arg; 207 (BadOpt) -> erlang:error({badoption, BadOpt}) end, 208 Opts = lists:map(MOpts, Options), 209 wxe_util:queue_cmd(This,X,Y, Opts,?get_env(),?wxGraphicsPath_Contains_3), 210 wxe_util:rec(?wxGraphicsPath_Contains_3). 211 212%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathgetbox">external documentation</a>. 213-spec getBox(This) -> {X::float(), Y::float(), W::float(), H::float()} when 214 This::wxGraphicsPath(). 215getBox(#wx_ref{type=ThisT}=This) -> 216 ?CLASS(ThisT,wxGraphicsPath), 217 wxe_util:queue_cmd(This,?get_env(),?wxGraphicsPath_GetBox), 218 wxe_util:rec(?wxGraphicsPath_GetBox). 219 220%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathgetcurrentpoint">external documentation</a>. 221-spec getCurrentPoint(This) -> {X::float(), Y::float()} when 222 This::wxGraphicsPath(). 223getCurrentPoint(#wx_ref{type=ThisT}=This) -> 224 ?CLASS(ThisT,wxGraphicsPath), 225 wxe_util:queue_cmd(This,?get_env(),?wxGraphicsPath_GetCurrentPoint), 226 wxe_util:rec(?wxGraphicsPath_GetCurrentPoint). 227 228%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxgraphicspath.html#wxgraphicspathtransform">external documentation</a>. 229-spec transform(This, Matrix) -> 'ok' when 230 This::wxGraphicsPath(), Matrix::wxGraphicsMatrix:wxGraphicsMatrix(). 231transform(#wx_ref{type=ThisT}=This,#wx_ref{type=MatrixT}=Matrix) -> 232 ?CLASS(ThisT,wxGraphicsPath), 233 ?CLASS(MatrixT,wxGraphicsMatrix), 234 wxe_util:queue_cmd(This,Matrix,?get_env(),?wxGraphicsPath_Transform). 235 236 %% From wxGraphicsObject 237%% @hidden 238isNull(This) -> wxGraphicsObject:isNull(This). 239%% @hidden 240getRenderer(This) -> wxGraphicsObject:getRenderer(This). 241