IUP

 view release on metacpan or  search on metacpan

lib/IUP.pm  view on Meta::CPAN

  $flag = 1 unless defined $flag; # default = 1 (create corresponding perl object if necessary)
  my $mapping = {
    #UPDATE when element list change
    animatedlabel   => 'IUP::AnimatedLabel',     # https://webserver2.tecgraf.puc-rio.br/iup/en/elem/iupanimatedlabel.html
    backgroundbox   => 'IUP::BackgroundBox',     # https://webserver2.tecgraf.puc-rio.br/iup/en/elem/iupbackgroundbox.html
    button          => 'IUP::Button',
    calendar        => 'IUP::Calendar',          # https://webserver2.tecgraf.puc-rio.br/iup/en/elem/iupcalendar.html
    canvas          => 'IUP::Canvas',
    cbox            => 'IUP::Cbox',
    cells           => 'IUP::Cells',
    clipboard       => 'IUP::Clipboard',
    colorbar        => 'IUP::ColorBar',
    colorbrowser    => 'IUP::ColorBrowser',
    colordlg        => 'IUP::ColorDlg',
    constants       => 'IUP::Constants',
    datepick        => 'IUP::DatePick',          # https://webserver2.tecgraf.puc-rio.br/iup/en/elem/iupdatepick.html
    detachbox       => 'IUP::DetachBox',         # https://webserver2.tecgraf.puc-rio.br/iup/en/elem/iupdetachbox.html
    dial            => 'IUP::Dial',
    dialog          => 'IUP::Dialog',
    expander        => 'IUP::Expander',
    filedlg         => 'IUP::FileDlg',

lib/IUP/Clipboard.pod  view on Meta::CPAN

=for comment based on iup-3.5 - http://www.tecgraf.puc-rio.br/iup/en/elem/iupclipboard.html

=head1 NAME

IUP::Clipboard - [special] allows access to the clipboard

=head1 DESCRIPTION 

Creates an element that allows access to the clipboard. Each clipboard
should be destroyed using L<Destroy|IUP::Manual::02_Elements/"Destroy()"> method, but
you can use only one for entire application because it does not store
any data inside. Or you can simply create and destroy everytime you
need to copy or paste.

Example - copy to clipboard:

 $text = IUP::Text->new();
 #...
 $clipboard = IUP::Clipboard->new();
 $clipboard->TEXT( $text->VALUE );
 $clipboard->Destroy();
 ###XXX-todo-not-tested

Example - paste from clipboard:

 $text = IUP::Text->new();
 #...
 $clipboard = IUP::Clipboard->new();
 $text->VALUE( $clipboard->TEXT );
 $clipboard->Destroy();
 ###XXX-todo-not-tested

=head1 USAGE

=head2 CREATION - new() method

 $clipboard = IUP::Clipboard->new();

B<Returns:> the identifier of the created element, or C<undef> if an error occurs.

NOTE: You can pass to C<new()> other C<ATTRIBUTE=E<gt>'value'> or C<CALLBACKNAME=E<gt>\&func> pairs relevant
to this element - see L<IUP::Manual::02_Elements|IUP::Manual::02_Elements/"new()">.

=head2 ATTRIBUTES

For more info about concept of attributes (setting/getting values etc.)
see L<IUP::Manual::03_Attributes|IUP::Manual::03_Attributes>. Attributes specific to this element:

=over

=item B<EMFAVAILABLE>

I<(read-only) [Windows Only]> informs if there is a
Windows Enhanced Metafile available at the clipboard. (Since iup-3.2)

=item B<IMAGE>

I<(write-only)> name of an image to copy (set) or paste (get),
to or from the clipboard. (GTK 2.6)

=item B<IMAGEAVAILABLE>

I<(read-only)> informs if there is an image available at the clipboard. (GTK 2.6)

=item B<NATIVEIMAGE>

Native handle of an image to copy or paste, to or from the clipboard.

B<BEWARE:> technically it is a pointer, be carefull when using from perl.

In Win32 is a B<HANDLE> of a DIB. 

In GTK is a B<GdkPixbuf*>. 

In Motif is a B<Pixmap>. 

The returned handle in a paste must be released after used (GlobalFree(handle), g_object_unref(pixbuf)
or XFreePixmap(display, pixmap)). After copy, do NOT release the given
handle. See IUP-IM Functions for utility functions on image native handles. (GTK 2.6)

=item B<SAVEEMF>

I<(write-only) [Windows Only]> saves the EMF from the
clipboard to the given filename. (Since iup-3.2)

=item B<SAVEWMF>

I<(write-only) [Windows Only]> saves the WMF from the
clipboard to the given filename. (Since iup-3.2)

=item B<TEXT>

copy or paste text to or from the clipboard.

=item B<TEXTAVAILABLE>

I<(read-only)> informs if there is a text available at the clipboard.

=item B<WMFAVAILABLE>

I<(read-only) [Windows Only]> informs if there is a
Windows Metafile available at the clipboard. (Since iup-3.2)

=back

=head1 EXAMPLES


Unfortunately there are no sample scripts using this element.



=head1 SEE ALSO

The original doc: L<iupclipboard.html|http://www.tecgraf.puc-rio.br/iup/en/elem/iupclipboard.html>
 

=cut

lib/IUP/LayoutDialog.pod  view on Meta::CPAN

You can NOT drag and drop elements in the layout. Using the right click
over an element shows a context menu, the same as in a tree node. When
an element in the layout is double clicked and the actual element is
visible, then the actual element will blink twice.

=head2 Context Menu

 Properties - shows the properties dialog for the selected element.
 Map - maps the selected element to the native system.
 Unmap - unmaps the selected element from the native system. Its attribute are saved before unmapping.
 Copy - copy the selected element to an internal clipboard. Its attributes are also copied.
 Paste Child - paste the copied element as the first child of the selected container. 
 Paste Brother - paste the copied element as brother of the selected element.
 Add Child - adds a new element as the first child of the selected container. The new element is not mapped.
 Add Brother - adds a new element as brother of the selected element. The new element is not mapped.
 Remove - removes the selected element. 

=head2 Properties

The properties dialog allows the inspection and change of the elements
attributes. It contains 3 Tab sections: one for the registered

lib/IUP/Scintilla.pod  view on Meta::CPAN

Shows a border around the text. Default: "YES".

=item * B<CANFOCUS> (creation only) (non inheritable)

enables the focus traversal of the control. In Windows the control will still get the
focus when clicked. Default: YES.

=item * B<CLIPBOARD> (non inheritable)

clear, cut, copy or paste the selection
to or from the clipboard. Values: "CLEAR", "CUT", "COPY", "PASTE".
Returns Yes or No, if data can be pasted from the clipboard.

=item * B<CURSOR> (non inheritable)

defines the cursor type. Can be: "NORMAL"
or "WAIT" (displays a wait cursor when the mouse is over or owned by the control).

=item * B<DROPFILESTARGET> [Windows and GTK Only] (non inheritable)

Enable or disable the drop of files. Default: NO, but if DROPFILES_CB is defined
when the element is mapped then it will be automatically enabled.

lib/IUP/Scintilla.pod  view on Meta::CPAN


For more info about concept of callbacks (setting callback handlers etc.)
see L<IUP::Manual::04_Callbacks|IUP::Manual::04_Callbacks>. Callbacks specific to this element:

=over

=item * L<ACTION|IUP::Manual::04_Callbacks/ACTION>

Action generated when the text is
edited, but before its value is actually changed. Can be generated when
using the keyboard, undo/redo system or from the clipboard.

 XXXXXX-TODO: int function(Ihandle *ih, int insert, int pos, int length, char* text ); [in C]elem:action(insert: boolean, pos, length: number, text: string) -> (ret: number) [in Lua]

B<$ih> - identifier of the element that activated the event.

B<$insert> - =1 when text is inserted, =0 when text is deleted.

B<$pos> - 0 based character position when change started.

B<$length> - size of the change.

lib/IUP/Text.pod  view on Meta::CPAN


Also the position of the insertion
point, but using a zero based character unique index "pos". Useful for
indexing the VALUE string.

=item B<CLIPBOARD>

I<(write-only)>

clear, cut, copy or paste the selection to
or from the clipboard. Values: "CLEAR", "CUT", "COPY" or "PASTE". In
Windows UNDO is also available, and REDO is available when
FORMATTING=YES. 

=item B<COUNT>

I<(read-only)>

Returns the number of characters in the text. (since iup-3.5)

=item B<CUEBANNER>

lib/IUP/Text.pod  view on Meta::CPAN


For more info about concept of callbacks (setting callback handlers etc.)
see L<IUP::Manual::04_Callbacks|IUP::Manual::04_Callbacks>. Callbacks specific to this element:

=over

=item L<ACTION|IUP::Manual::04_Callbacks/ACTION>

Action generated when the text is
edited, but before its value is actually changed. Can be generated when
using the keyboard, undo system or from the clipboard.

B<Callback handler prototype:>

 sub action_handler {
   my ($self, $c, $new_value) = @_;
   #...
 }

=over



( run in 4.727 seconds using v1.01-cache-2.11-cpan-2398b32b56e )