%%
%% %CopyrightBegin%
%%
%% Copyright Ericsson AB 2008-2016. All Rights Reserved.
%%
%% Licensed under the Apache License, Version 2.0 (the "License");
%% you may not use this file except in compliance with the License.
%% You may obtain a copy of the License at
%%
%% http://www.apache.org/licenses/LICENSE-2.0
%%
%% Unless required by applicable law or agreed to in writing, software
%% distributed under the License is distributed on an "AS IS" BASIS,
%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
%% See the License for the specific language governing permissions and
%% limitations under the License.
%%
%% %CopyrightEnd%
%% This file is generated DO NOT EDIT
%% @doc See external documentation: wxListItem.
%% @type wxListItem(). 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(wxListItem).
-include("wxe.hrl").
-export([clear/1,destroy/1,getAlign/1,getBackgroundColour/1,getColumn/1,getFont/1,
getId/1,getImage/1,getMask/1,getState/1,getText/1,getTextColour/1,getWidth/1,
new/0,new/1,setAlign/2,setBackgroundColour/2,setColumn/2,setFont/2,
setId/2,setImage/2,setMask/2,setState/2,setStateMask/2,setText/2,setTextColour/2,
setWidth/2]).
%% inherited exports
-export([parent_class/1]).
-export_type([wxListItem/0]).
%% @hidden
parent_class(_Class) -> erlang:error({badtype, ?MODULE}).
-type wxListItem() :: wx:wx_object().
%% @doc See external documentation.
-spec new() -> wxListItem().
new() ->
wxe_util:construct(?wxListItem_new_0,
<<>>).
%% @doc See external documentation.
-spec new(Item) -> wxListItem() when
Item::wxListItem().
new(#wx_ref{type=ItemT,ref=ItemRef}) ->
?CLASS(ItemT,wxListItem),
wxe_util:construct(?wxListItem_new_1,
<>).
%% @doc See external documentation.
-spec clear(This) -> 'ok' when
This::wxListItem().
clear(#wx_ref{type=ThisT,ref=ThisRef}) ->
?CLASS(ThisT,wxListItem),
wxe_util:cast(?wxListItem_Clear,
<>).
%% @doc See external documentation.
%%
Res = ?wxLIST_FORMAT_LEFT | ?wxLIST_FORMAT_RIGHT | ?wxLIST_FORMAT_CENTRE | ?wxLIST_FORMAT_CENTER
-spec getAlign(This) -> wx:wx_enum() when
This::wxListItem().
getAlign(#wx_ref{type=ThisT,ref=ThisRef}) ->
?CLASS(ThisT,wxListItem),
wxe_util:call(?wxListItem_GetAlign,
<>).
%% @doc See external documentation.
-spec getBackgroundColour(This) -> wx:wx_colour4() when
This::wxListItem().
getBackgroundColour(#wx_ref{type=ThisT,ref=ThisRef}) ->
?CLASS(ThisT,wxListItem),
wxe_util:call(?wxListItem_GetBackgroundColour,
<>).
%% @doc See external documentation.
-spec getColumn(This) -> integer() when
This::wxListItem().
getColumn(#wx_ref{type=ThisT,ref=ThisRef}) ->
?CLASS(ThisT,wxListItem),
wxe_util:call(?wxListItem_GetColumn,
<>).
%% @doc See external documentation.
-spec getFont(This) -> wxFont:wxFont() when
This::wxListItem().
getFont(#wx_ref{type=ThisT,ref=ThisRef}) ->
?CLASS(ThisT,wxListItem),
wxe_util:call(?wxListItem_GetFont,
<>).
%% @doc See external documentation.
-spec getId(This) -> integer() when
This::wxListItem().
getId(#wx_ref{type=ThisT,ref=ThisRef}) ->
?CLASS(ThisT,wxListItem),
wxe_util:call(?wxListItem_GetId,
<>).
%% @doc See external documentation.
-spec getImage(This) -> integer() when
This::wxListItem().
getImage(#wx_ref{type=ThisT,ref=ThisRef}) ->
?CLASS(ThisT,wxListItem),
wxe_util:call(?wxListItem_GetImage,
<>).
%% @doc See external documentation.
-spec getMask(This) -> integer() when
This::wxListItem().
getMask(#wx_ref{type=ThisT,ref=ThisRef}) ->
?CLASS(ThisT,wxListItem),
wxe_util:call(?wxListItem_GetMask,
<>).
%% @doc See external documentation.
-spec getState(This) -> integer() when
This::wxListItem().
getState(#wx_ref{type=ThisT,ref=ThisRef}) ->
?CLASS(ThisT,wxListItem),
wxe_util:call(?wxListItem_GetState,
<>).
%% @doc See external documentation.
-spec getText(This) -> unicode:charlist() when
This::wxListItem().
getText(#wx_ref{type=ThisT,ref=ThisRef}) ->
?CLASS(ThisT,wxListItem),
wxe_util:call(?wxListItem_GetText,
<>).
%% @doc See external documentation.
-spec getTextColour(This) -> wx:wx_colour4() when
This::wxListItem().
getTextColour(#wx_ref{type=ThisT,ref=ThisRef}) ->
?CLASS(ThisT,wxListItem),
wxe_util:call(?wxListItem_GetTextColour,
<>).
%% @doc See external documentation.
-spec getWidth(This) -> integer() when
This::wxListItem().
getWidth(#wx_ref{type=ThisT,ref=ThisRef}) ->
?CLASS(ThisT,wxListItem),
wxe_util:call(?wxListItem_GetWidth,
<>).
%% @doc See external documentation.
%%
Align = ?wxLIST_FORMAT_LEFT | ?wxLIST_FORMAT_RIGHT | ?wxLIST_FORMAT_CENTRE | ?wxLIST_FORMAT_CENTER
-spec setAlign(This, Align) -> 'ok' when
This::wxListItem(), Align::wx:wx_enum().
setAlign(#wx_ref{type=ThisT,ref=ThisRef},Align)
when is_integer(Align) ->
?CLASS(ThisT,wxListItem),
wxe_util:cast(?wxListItem_SetAlign,
<>).
%% @doc See external documentation.
-spec setBackgroundColour(This, ColBack) -> 'ok' when
This::wxListItem(), ColBack::wx:wx_colour().
setBackgroundColour(#wx_ref{type=ThisT,ref=ThisRef},ColBack)
when tuple_size(ColBack) =:= 3; tuple_size(ColBack) =:= 4 ->
?CLASS(ThisT,wxListItem),
wxe_util:cast(?wxListItem_SetBackgroundColour,
<>).
%% @doc See external documentation.
-spec setColumn(This, Col) -> 'ok' when
This::wxListItem(), Col::integer().
setColumn(#wx_ref{type=ThisT,ref=ThisRef},Col)
when is_integer(Col) ->
?CLASS(ThisT,wxListItem),
wxe_util:cast(?wxListItem_SetColumn,
<>).
%% @doc See external documentation.
-spec setFont(This, Font) -> 'ok' when
This::wxListItem(), Font::wxFont:wxFont().
setFont(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=FontT,ref=FontRef}) ->
?CLASS(ThisT,wxListItem),
?CLASS(FontT,wxFont),
wxe_util:cast(?wxListItem_SetFont,
<>).
%% @doc See external documentation.
-spec setId(This, Id) -> 'ok' when
This::wxListItem(), Id::integer().
setId(#wx_ref{type=ThisT,ref=ThisRef},Id)
when is_integer(Id) ->
?CLASS(ThisT,wxListItem),
wxe_util:cast(?wxListItem_SetId,
<>).
%% @doc See external documentation.
-spec setImage(This, Image) -> 'ok' when
This::wxListItem(), Image::integer().
setImage(#wx_ref{type=ThisT,ref=ThisRef},Image)
when is_integer(Image) ->
?CLASS(ThisT,wxListItem),
wxe_util:cast(?wxListItem_SetImage,
<>).
%% @doc See external documentation.
-spec setMask(This, Mask) -> 'ok' when
This::wxListItem(), Mask::integer().
setMask(#wx_ref{type=ThisT,ref=ThisRef},Mask)
when is_integer(Mask) ->
?CLASS(ThisT,wxListItem),
wxe_util:cast(?wxListItem_SetMask,
<>).
%% @doc See external documentation.
-spec setState(This, State) -> 'ok' when
This::wxListItem(), State::integer().
setState(#wx_ref{type=ThisT,ref=ThisRef},State)
when is_integer(State) ->
?CLASS(ThisT,wxListItem),
wxe_util:cast(?wxListItem_SetState,
<>).
%% @doc See external documentation.
-spec setStateMask(This, StateMask) -> 'ok' when
This::wxListItem(), StateMask::integer().
setStateMask(#wx_ref{type=ThisT,ref=ThisRef},StateMask)
when is_integer(StateMask) ->
?CLASS(ThisT,wxListItem),
wxe_util:cast(?wxListItem_SetStateMask,
<>).
%% @doc See external documentation.
-spec setText(This, Text) -> 'ok' when
This::wxListItem(), Text::unicode:chardata().
setText(#wx_ref{type=ThisT,ref=ThisRef},Text)
when ?is_chardata(Text) ->
?CLASS(ThisT,wxListItem),
Text_UC = unicode:characters_to_binary([Text,0]),
wxe_util:cast(?wxListItem_SetText,
<>).
%% @doc See external documentation.
-spec setTextColour(This, ColText) -> 'ok' when
This::wxListItem(), ColText::wx:wx_colour().
setTextColour(#wx_ref{type=ThisT,ref=ThisRef},ColText)
when tuple_size(ColText) =:= 3; tuple_size(ColText) =:= 4 ->
?CLASS(ThisT,wxListItem),
wxe_util:cast(?wxListItem_SetTextColour,
<>).
%% @doc See external documentation.
-spec setWidth(This, Width) -> 'ok' when
This::wxListItem(), Width::integer().
setWidth(#wx_ref{type=ThisT,ref=ThisRef},Width)
when is_integer(Width) ->
?CLASS(ThisT,wxListItem),
wxe_util:cast(?wxListItem_SetWidth,
<>).
%% @doc Destroys this object, do not use object again
-spec destroy(This::wxListItem()) -> 'ok'.
destroy(Obj=#wx_ref{type=Type}) ->
?CLASS(Type,wxListItem),
wxe_util:destroy(?DESTROY_OBJECT,Obj),
ok.