Changeset 7941 for lang/perl/Acme-Shukugawa-Atom
- Timestamp:
- 03/14/08 10:06:37 (9 months ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
lang/perl/Acme-Shukugawa-Atom/trunk/lib/Acme/Shukugawa/Atom.pm
r7939 r7941 17 17 # Special case handling -- this could be optimized further 18 18 # put it in a sharefile later 19 our ( @DEFAULT_WORDS, $RE_EXCEPTION, $RE_SMALL, $RE_SYLLABLE, $RE_NBAR);19 our ($CONFIG, @DEFAULT_WORDS, $RE_EXCEPTION, $RE_SMALL, $RE_SYLLABLE, $RE_NBAR); 20 20 BEGIN 21 21 { 22 my $config = YAML::LoadFile( File::ShareDir::module_file(__PACKAGE__, 'config.yaml') ); 22 my $config = YAML::LoadFile( 23 $CONFIG || File::ShareDir::module_file(__PACKAGE__, 'config.yaml') ); 23 24 $RE_SMALL = decode_utf8("[ャュョッー]"); 24 25 $RE_SYLLABLE = decode_utf8("(?:.$RE_SMALL?)"); … … 233 234 my $newstring = Acme::Shukugawa::Atom->translate($string); 234 235 236 # By default, share/config.yaml is used (via File::ShareDir) for custom 237 # fixed replacements. You can however override this by specifying the 238 # alternate config filename at load time 239 BEGIN 240 { 241 $Acme::Shukugawa::Atom::CONFIG = '/path/to/config.yaml'; 242 } 243 use Acme::Shukugawa::Atom; 244 245 # Or you can specify them (on top of the default words) at run time 235 246 my $atom = Acme::Shukugawa::Atom->new( 236 247 # The default values are stored in @Acme::Shukugawa::Atom::DEFAULT_WORDS
![(please configure the [header_logo] section in trac.ini)](/share/chrome/site/your_project_logo.png)