Description | Perl tools for X-ray Absorption Spectroscopy |
Demeter::UI::Wx::EchoArea - A run-time feedback widget
This documentation refers to Demeter version 0.9.26.
An echo area an be added to a Wx application:
my $echoarea = Demeter::UI::Wx::EchoArea->new($self);
$sizer -> Add($echoarea, 0, wxEXPAND|wxALL, 3);
The argument to the constructor method is a reference to the parent in which this is placed. This is used as the echo area for all Hephaestus utilities.
This is derived from Wx::TextCrtl and is intended to serve as an echo area in a Wx application in much the similar fashion as Emacs' echo area.
echo
Insert text into the echo area and push that text onto the echo buffer.
$echoarea->echo("Hi there!");
To clear the echo area without clearing the echo buffer, give this method an empty string:
$echoarea->echo(q{});
This method returns the reference to the EchoArea widget.
buffer
Return the contents of the echo buffer as an array.
@contents = $echoarea->buffer;
buffer_as_text
Return the contents of the echo buffer as a simply formatted text string.
$contents = $echoarea->buffer_as_text;
Length
Return the length of echo buffer.
$len = $echoarea->Length
clear
Clear the echo area and empty the echo buffer.
$echoarea->clear;
This method returns the reference to the EchoArea widget.
Demeter's dependencies are in the Build.PL file.
Artemis & Athena will require a data entry mode. That could be done by liftingt he readonly flag, changing the background color, and grabbing focus until carriage return is pressed.
Need configurable text color and max length. Need warn and error modes and configurable colors for those.
Please report problems to the Ifeffit Mailing List (http://cars9.uchicago.edu/mailman/listinfo/ifeffit/)
Patches are welcome.
Bruce Ravel (http://bruceravel.github.io/home)
http://bruceravel.github.io/demeter/
Copyright (c) 2006-2018 Bruce Ravel (http://bruceravel.github.io/home). All rights reserved.
This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See perlgpl.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.