| 1 | package Padre::Plugin::SpellCheck::FBP::Preferences; | ||
| 2 | |||
| 3 | ## no critic | ||
| 4 | |||
| 5 | # This module was generated by Padre::Plugin::FormBuilder::Perl. | ||
| 6 | # To change this module edit the original .fbp file and regenerate. | ||
| 7 | # DO NOT MODIFY THIS FILE BY HAND! | ||
| 8 | |||
| 9 | 2 | ▶ | use 5.008005; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 10 | 2 | ▶ | use utf8; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 11 | 2 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 12 | 2 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 13 | 0 | ▶ | use Padre::Wx (); |
|
Subroutine
BEGIN: called CC=1 SCAR=2.6
| |||
| 14 | use Padre::Wx::Role::Main (); | ||
| 15 | |||
| 16 | our $VERSION = '1.33'; | ||
| 17 | our @ISA = qw{ | ||
| 18 | Padre::Wx::Role::Main | ||
| 19 | Wx::Dialog | ||
| 20 | }; | ||
| 21 | |||
| 22 | sub new { | ||
| 23 | my $class = shift; | ||
| 24 | my $parent = shift; | ||
| 25 | |||
| 26 | my $self = $class->SUPER::new( | ||
| 27 | $parent, | ||
| 28 | -1, | ||
| 29 | Wx::gettext("Spelling preferences"), | ||
| 30 | Wx::DefaultPosition, | ||
| 31 | Wx::DefaultSize, | ||
| 32 | Wx::DEFAULT_DIALOG_STYLE | Wx::RESIZE_BORDER, | ||
| 33 | ); | ||
| 34 | |||
| 35 | $self->{chosen_dictionary} = Wx::RadioBox->new( | ||
| 36 | $self, | ||
| 37 | -1, | ||
| 38 | Wx::gettext("Dictionary"), | ||
| 39 | Wx::DefaultPosition, | ||
| 40 | Wx::DefaultSize, | ||
| 41 | [ | ||
| 42 | "Aspell", | ||
| 43 | "Hunspell", | ||
| 44 | ], | ||
| 45 | 1, | ||
| 46 | Wx::RA_SPECIFY_ROWS, | ||
| 47 | ); | ||
| 48 | $self->{chosen_dictionary}->SetSelection(0); | ||
| 49 | |||
| 50 | Wx::Event::EVT_RADIOBOX( | ||
| 51 | $self, | ||
| 52 | $self->{chosen_dictionary}, | ||
| 53 | sub { | ||
| 54 | shift->on_dictionary_chosen(@_); | ||
| 55 | }, | ||
| 56 | ); | ||
| 57 | |||
| 58 | $self->{language} = Wx::Choice->new( | ||
| 59 | $self, | ||
| 60 | -1, | ||
| 61 | Wx::DefaultPosition, | ||
| 62 | [ 220, -1 ], | ||
| 63 | [], | ||
| 64 | ); | ||
| 65 | $self->{language}->SetSelection(0); | ||
| 66 | |||
| 67 | $self->{m_sdbSizer1_save} = Wx::Button->new( | ||
| 68 | $self, | ||
| 69 | Wx::ID_SAVE, | ||
| 70 | ); | ||
| 71 | |||
| 72 | Wx::Event::EVT_BUTTON( | ||
| 73 | $self, | ||
| 74 | $self->{m_sdbSizer1_save}, | ||
| 75 | sub { | ||
| 76 | shift->_on_button_save_clicked(@_); | ||
| 77 | }, | ||
| 78 | ); | ||
| 79 | |||
| 80 | $self->{m_sdbSizer1_cancel} = Wx::Button->new( | ||
| 81 | $self, | ||
| 82 | Wx::ID_CANCEL, | ||
| 83 | ); | ||
| 84 | |||
| 85 | $self->{sbSizer4} = Wx::StaticBoxSizer->new( | ||
| 86 | Wx::StaticBox->new( | ||
| 87 | $self, | ||
| 88 | -1, | ||
| 89 | Wx::gettext("Select Dictionary and Language"), | ||
| 90 | ), | ||
| 91 | Wx::VERTICAL, | ||
| 92 | ); | ||
| 93 | $self->{sbSizer4}->Add( $self->{chosen_dictionary}, 0, Wx::ALL | Wx::EXPAND, 5 ); | ||
| 94 | $self->{sbSizer4}->Add( $self->{language}, 0, Wx::ALL, 5 ); | ||
| 95 | |||
| 96 | $self->{m_sdbSizer1} = Wx::StdDialogButtonSizer->new; | ||
| 97 | $self->{m_sdbSizer1}->AddButton( $self->{m_sdbSizer1_save} ); | ||
| 98 | $self->{m_sdbSizer1}->AddButton( $self->{m_sdbSizer1_cancel} ); | ||
| 99 | $self->{m_sdbSizer1}->Realize; | ||
| 100 | |||
| 101 | my $bSizer1 = Wx::BoxSizer->new(Wx::VERTICAL); | ||
| 102 | $bSizer1->Add( $self->{sbSizer4}, 1, Wx::ALL | Wx::EXPAND, 5 ); | ||
| 103 | $bSizer1->Add( $self->{m_sdbSizer1}, 0, Wx::ALL | Wx::EXPAND, 5 ); | ||
| 104 | |||
| 105 | $self->SetSizerAndFit($bSizer1); | ||
| 106 | $self->Layout; | ||
| 107 | |||
| 108 | return $self; | ||
| 109 | } | ||
| 110 | |||
| 111 | sub chosen_dictionary { | ||
| 112 | $_[0]->{chosen_dictionary}; | ||
| 113 | } | ||
| 114 | |||
| 115 | sub language { | ||
| 116 | $_[0]->{language}; | ||
| 117 | } | ||
| 118 | |||
| 119 | sub on_dictionary_chosen { | ||
| 120 | $_[0]->main->error('Handler method on_dictionary_chosen for event chosen_dictionary.OnRadioBox not implemented'); | ||
| 121 | } | ||
| 122 | |||
| 123 | sub _on_button_ok_clicked { | ||
| 124 | $_[0]->main->error('Handler method _on_button_ok_clicked for event m_sdbSizer1.OnOKButtonClick not implemented'); | ||
| 125 | } | ||
| 126 | |||
| 127 | sub _on_button_save_clicked { | ||
| 128 | $_[0]->main->error('Handler method _on_button_save_clicked for event m_sdbSizer1.OnSaveButtonClick not implemented'); | ||
| 129 | } | ||
| 130 | |||
| 131 | 1; | ||
| 132 | |||
| 133 | # Copyright 2008-2013 The Padre development team as listed in Padre.pm. | ||
| 134 | # LICENSE | ||
| 135 | # This program is free software; you can redistribute it and/or | ||
| 136 | # modify it under the same terms as Perl 5 itself. | ||
| 137 | |||