use Prima::StdDlg;
my $dlg = Prima::FindDialog-> create( findStyle => 0);
my $res = $dlg-> execute;
if ( $res == mb::Ok) {
print $dlg-> findText, " is to be found\n";
} elsif ( $res == mb::ChangeAll) {
print "all occurences of ", $dlg-> findText,
" is to be replaced by ", $dlg-> replaceText;
}
The "mb::ChangeAll" constant, one of possible results of "execute" method, is defined in Prima::StdDlg module. Therefore it is recommended to include this module instead.
The module does not provide the actual search algorithm; this must be implemented by the programmer. The toolkit currently include some facilitation to the problem - the part of algorithm for "Prima::Edit" class is found in ``find'' in Prima::Edit, and the another part - in examples/editor.pl example program. Prima::HelpWindow also uses the module, and realizes its own searching algorithm.
Default value: ''
Default value: 1 for "Prima::FindDialog", 0 for "Prima::ReplaceDialog".
fdo::MatchCase
fdo::WordsOnly
fdo::RegularExpression
fdo::BackwardSearch
fdo::ReplacePrompt
Default value: 0
Default value: ''
fds::Cursor
fds::Top
fds::Bottom
Default value: "fds::Cursor"