"Fossies" - the Fresh Open Source Software Archive 
As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Perl source code syntax highlighting (style:
standard) with prefixed line numbers and
code folding option.
Alternatively you can here
view or
download the uninterpreted source code file.
For more information about "config.pm" see the
Fossies "Dox" file reference documentation.
1 use strict;
2 use warnings;
3
4 #--------------------------------------------------------------------------------------------------------------
5 # Save Config File
6 #--------------------------------------------------------------------------------------------------------------
7
8 # MEMO: to self, config file is for stuff under prefs dialog only and defaults is for mainwindow vars
9 sub save_config
10 {
11 open(FILE, ">$main::config_file");
12 print FILE "\# namefix.pl $main::version config file\n",
13 "\# treated as perl script - dont fuck up if doing manual edit.\n\n";
14
15 print FILE
16
17 "\$space_character = \"$main::space_character\";\n",
18 "\$max_fn_length = $main::max_fn_length;\n",
19 "\n",
20 "\$fat32fix = $main::fat32fix;\n",
21 "\$disable_regexp = $main::disable_regexp;\n",
22 "\$file_ext_2_proc = \"$main::file_ext_2_proc\";\n",
23 "\$debug = $main::debug;\n",
24 "\$LOG_STDOUT = $main::LOG_STDOUT;\n",
25 "\$ERROR_STDOUT = $main::ERROR_STDOUT;\n",
26 "\$ERROR_NOTIFY = $main::ERROR_NOTIFY;\n",
27 "\$ZERO_LOG = $main::ZERO_LOG;\n",
28 "\$HTML_HACK = $main::HTML_HACK;\n",
29 "\$browser = \"$main::browser\";\n",
30 "\$editor = \"$main::editor\";\n",
31 "\n",
32 "\n";
33
34 if
35 (
36 $main::load_defaults == 1 || # gui option user selects to save mainwindow options
37 $main::CLI # if running from cli, save options
38 ) {
39
40 print FILE
41
42 "\n\# main window options\n\n",
43
44 "\$case = $main::case;\n",
45 "\$sp_word = $main::sp_word;\n",
46
47 "\$spaces = $main::spaces;\n",
48 "\$dot2space = $main::dot2space;\n",
49 "\$kill_cwords = $main::kill_cwords;\n",
50 "\$kill_sp_patterns = $main::kill_sp_patterns;\n",
51 "\$sp_char = $main::sp_char;\n",
52 "\$intr_char = $main::intr_char;\n",
53
54 "\$lc_all = $main::lc_all;\n",
55 "\$uc_all = $main::uc_all;\n",
56
57 "\$id3_mode = $main::id3_mode;\n",
58 "\$id3_guess_tag = $main::id3_guess_tag;\n",
59
60 "\$enum_opt = $main::enum_opt;\n",
61 "\$enum_pad = $main::enum_pad;\n",
62 "\$enum_pad_zeros = $main::enum_pad_zeros;\n",
63
64 "\$truncate = $main::truncate;\n",
65 "\$truncate_style = $main::truncate_style;\n",
66 "\$trunc_char = \"$main::trunc_char\";\n",
67 "\$truncate_to = \"$main::truncate_to\";\n",
68
69 "\n";
70 }
71
72 if($main::SAVE_WINDOW_SIZE == 1 && !$main::CLI)
73 {
74 $main::window_g = $main::mw->geometry;
75
76 print FILE
77
78 "\$save_window_size = 1;\n",
79 "\$window_g = \"$main::window_g\";\n\n";
80 }
81 print FILE "\# end of config file";
82 close(FILE);
83 }
84
85
86 1;