comparison libgui/src/gui-preferences-ve.h @ 31599:50a225732661 stable

use initializer lists instead of insertion operators * gui-preferences-cs.h, gui-preferences-ed.h, gui-preferences-global.h, gui-preferences-ve.h, gui-preferences-ws.h, main-window.cc: Where possible, use initializer lists ({ a, b, ... }) instead of insertion operators (QStringList () << a << b << ...).
author John W. Eaton <jwe@octave.org>
date Thu, 01 Dec 2022 12:50:48 -0500
parents 796f54d4ddbf
children aae24eaf89ad 597f3ee61a48
comparison
equal deleted inserted replaced
31596:e03694e047fa 31599:50a225732661
68 {"variable_editor/color_s" + settings_color_modes_ext[1], QVariant ()}, 68 {"variable_editor/color_s" + settings_color_modes_ext[1], QVariant ()},
69 {"variable_editor/color_h" + settings_color_modes_ext[1], QVariant ()}, 69 {"variable_editor/color_h" + settings_color_modes_ext[1], QVariant ()},
70 {"variable_editor/color_a" + settings_color_modes_ext[1], QVariant ()} 70 {"variable_editor/color_a" + settings_color_modes_ext[1], QVariant ()}
71 }; 71 };
72 72
73 const QStringList ve_color_names (QStringList () 73 const QStringList ve_color_names = {
74 << QT_TRANSLATE_NOOP ("octave::settings_dialog", "Foreground") 74 QT_TRANSLATE_NOOP ("octave::settings_dialog", "Foreground"),
75 << QT_TRANSLATE_NOOP ("octave::settings_dialog", "Background") 75 QT_TRANSLATE_NOOP ("octave::settings_dialog", "Background"),
76 << QT_TRANSLATE_NOOP ("octave::settings_dialog", "Selected Foreground") 76 QT_TRANSLATE_NOOP ("octave::settings_dialog", "Selected Foreground"),
77 << QT_TRANSLATE_NOOP ("octave::settings_dialog", "Selected Background") 77 QT_TRANSLATE_NOOP ("octave::settings_dialog", "Selected Background"),
78 << QT_TRANSLATE_NOOP ("octave::settings_dialog", "Alternate Background")); 78 QT_TRANSLATE_NOOP ("octave::settings_dialog", "Alternate Background")
79 };
79 80
80 const QStringList ve_save_formats (QStringList () 81 const QStringList ve_save_formats = {
81 << "ascii" 82 "ascii",
82 << "binary" 83 "binary",
83 << "float-binary" 84 "float-binary",
84 << "hdf5" 85 "hdf5",
85 << "float-hdf5" 86 "float-hdf5",
86 << "text" 87 "text",
87 << "mat7-binary" 88 "mat7-binary",
88 << "mat-binary" 89 "mat-binary",
89 << "mat4-binary" 90 "mat4-binary",
90 << "zip"); 91 "zip"
92 };
91 93
92 // The following list is a relation between save format and fiel extension. 94 // The following list is a relation between save format and fiel extension.
93 // The format string are case insensitive. 95 // The format string are case insensitive.
94 const QStringList ve_save_formats_ext (QStringList () 96 const QStringList ve_save_formats_ext = {
95 << "-ascii" << "dat" 97 "-ascii", "dat",
96 << "-hdf5" << "h5" 98 "-hdf5", "h5",
97 << "-text" << "txt" 99 "-text", "txt",
98 << "-v7.3" << "mat" 100 "-v7.3", "mat",
99 << "-7.3" << "mat" 101 "-7.3", "mat",
100 << "-v7" << "mat" 102 "-v7", "mat",
101 << "-7" << "mat" 103 "-7", "mat",
102 << "-mat7-binary" << "mat" 104 "-mat7-binary", "mat",
103 << "-v6" << "mat" 105 "-v6", "mat",
104 << "-6" << "mat" 106 "-6", "mat",
105 << "-mat-binary" << "mat" 107 "-mat-binary", "mat",
106 << "-v4" << "mat" 108 "-v4", "mat",
107 << "-4" << "mat" 109 "-4", "mat",
108 << "-mat4-binary" << "mat" 110 "-mat4-binary", "mat",
109 << "-binary" << "bin" // after other fmt incl. "-binary" 111 "-binary", "bin", // after other fmt incl. "-binary"
110 << "-z" << "txt.gz" // gzipped -text 112 "-z", "txt.gz" // gzipped -text
111 ); 113 };
112 114
113 #endif 115 #endif