| 1 |
Descriptionscip-debian debian qutemol 0.4.1~cvs20081111-15 qutemol/patches/`16_mytab.cpp.patch`#Description.: Modifications to src/MyTab.cpp |
| 2 |
Fix spelling error: 'Strenght' instead of 'Strength' |
| 3 |
Authorscip-debian debian qutemol 0.4.1~cvs20081111-15 qutemol/patches/`16_mytab.cpp.patch`#Author.: Morten Kjeldgaard <[email protected]scip-debian . . . identity/`[email protected]`.> |
| 4 |
Authorscip-debian debian qutemol 0.4.1~cvs20081111-15 qutemol/patches/`16_mytab.cpp.patch`#Author.: Graham Inggs <[email protected]scip-debian . . . identity/`[email protected]`.> |
| 5 |
Last-Updatescip-debian debian qutemol 0.4.1~cvs20081111-15 qutemol/patches/`16_mytab.cpp.patch`#Last-Update.: 2021-10-04 |
| 6 |
|
| 7 |
--- a/src/MyTab.cppscip-debian debian qutemol 0.4.1~cvs20081111-15 qutemol/upstream/`src/MyTab.cpp`: |
| 8 |
+++ b/src/MyTab.cppscip-debian debian qutemol 0.4.1~cvs20081111-15 qutemol/upstream/`src/MyTab.cpp`: |
| 9 |
@@ -28,7 +28,7 @@ |
| 10 |
// GEOM TAB |
| 11 |
//////////// |
| 12 |
|
| 13 |
|
| 14 |
+static enum { ID_SetBallnstick=500, ID_SetSpacefill, ID_SetLicorice, |
| 15 |
ID_SetLicoriceRadius, ID_SetBallnstickRadius, |
| 16 |
|
| 17 |
ID_SetBallnstickSmoothcolor,ID_SetBallnstickBicolor, ID_SetBallnstickConstantcolor, |
| 18 |
@@ -93,7 +93,8 @@ |
| 19 |
static wxCheckBox *buttonSetHetatm; |
| 20 |
|
| 21 |
static wxSlider *sliderLicorice, *sliderBallnstick, |
| 22 |
|
| 23 |
+ //*sliderSetBaseColor , |
| 24 |
+ *sliderShineSize, |
| 25 |
*sliderAwaren , |
| 26 |
*sliderSetBgbrightness, |
| 27 |
*sliderLightBase, *sliderLighting, *sliderAO, |
| 28 |
@@ -114,49 +115,49 @@ |
| 29 |
const int NPreset=15; |
| 30 |
static wxButton* preset[NPreset]; |
| 31 |
|
| 32 |
|
| 33 |
|
| 34 |
|
| 35 |
|
| 36 |
|
| 37 |
|
| 38 |
|
| 39 |
|
| 40 |
|
| 41 |
|
| 42 |
|
| 43 |
|
| 44 |
|
| 45 |
|
| 46 |
|
| 47 |
|
| 48 |
|
| 49 |
|
| 50 |
|
| 51 |
|
| 52 |
+static const char* presetFile[NPreset] = { |
| 53 |
+ "real.preset", |
| 54 |
+ "real2.preset", |
| 55 |
+ "direct.preset", |
| 56 |
+ |
| 57 |
+ "illustr.preset", |
| 58 |
+ "illustr_new.preset", |
| 59 |
+ "illustr_motm.preset", |
| 60 |
+ |
| 61 |
+ "qutemol1.preset", |
| 62 |
+ "qutemol2.preset", |
| 63 |
+ "qutemol3.preset", |
| 64 |
+ |
| 65 |
+ "coolb.preset", |
| 66 |
+ "coold.preset", |
| 67 |
+ "borders_cool.preset", |
| 68 |
+ |
| 69 |
+ "sem.preset", |
| 70 |
+ "sem2.preset", |
| 71 |
+ "shape.preset", |
| 72 |
}; |
| 73 |
|
| 74 |
|
| 75 |
|
| 76 |
|
| 77 |
|
| 78 |
|
| 79 |
|
| 80 |
|
| 81 |
|
| 82 |
|
| 83 |
|
| 84 |
|
| 85 |
|
| 86 |
|
| 87 |
|
| 88 |
|
| 89 |
|
| 90 |
|
| 91 |
|
| 92 |
|
| 93 |
|
| 94 |
|
| 95 |
+static const char* presetName[NPreset]={ |
| 96 |
+ "Realistic 1", |
| 97 |
+ "Realistic 2", |
| 98 |
+ "Direct\nLight Only", |
| 99 |
+ |
| 100 |
+ "Illustr-\native 1", |
| 101 |
+ "Illustr-\native 2", |
| 102 |
+ "Molecule of\nthe Month", |
| 103 |
+ |
| 104 |
+ "Mixed 1", |
| 105 |
+ "Mixed 2", |
| 106 |
+ "Mixed 3", |
| 107 |
+ |
| 108 |
+ "Cool\n(bright)", |
| 109 |
+ "Cool\n(dark)", |
| 110 |
+ "Cool\nborders", |
| 111 |
+ |
| 112 |
+ "Simulated\nS.E.M. 1", |
| 113 |
+ "Simulated\nS.E.M. 2", |
| 114 |
+ "Shape\nPerception" |
| 115 |
}; |
| 116 |
|
| 117 |
static bool presetEndOfLine[NPreset] = { |
| 118 |
@@ -490,9 +491,9 @@ |
| 119 |
default: |
| 120 |
int pid=id-ID_FirstPreset; |
| 121 |
if ( (pid>=0) && (pid<NPreset) ) { |
| 122 |
|
| 123 |
|
| 124 |
|
| 125 |
+#ifndef _WIN32 |
| 126 |
+ wxString presetPath = _T(PKGDATADIR"/presets/") + wxString::FromAscii(presetFile[pid]); |
| 127 |
+ if (!cgSettings.Load( (const char *)presetPath.ToAscii() )) { |
| 128 |
#else |
| 129 |
if (!cgSettings.Load( presetFile[pid] )) { |
| 130 |
#endif |
| 131 |
@@ -815,11 +816,16 @@ |
| 132 |
wxString noNewLine(wxString x){ |
| 133 |
static wxString res; |
| 134 |
res.Clear(); |
| 135 |
|
| 136 |
|
| 137 |
|
| 138 |
|
| 139 |
|
| 140 |
+ |
| 141 |
+ for (int i=0; i< (int)x.Length(); i++){ |
| 142 |
+ if ((x[i]=='-')&&(x[i+1]=='\n')) { |
| 143 |
+ i++; i++; |
| 144 |
+ } |
| 145 |
+ if (x[i] != '\n') { |
| 146 |
+ res.Append(x[i]); |
| 147 |
+ } else { |
| 148 |
+ res.Append(' '); |
| 149 |
+ } |
| 150 |
} |
| 151 |
return res; |
| 152 |
} |
| 153 |
@@ -828,10 +834,10 @@ |
| 154 |
/*wxNO_FULL_REPAINT_ON_RESIZE |*/ wxCLIP_CHILDREN | wxTAB_TRAVERSAL) |
| 155 |
{ |
| 156 |
|
| 157 |
|
| 158 |
+ //int i; |
| 159 |
|
| 160 |
bool thinButtons=false; |
| 161 |
|
| 162 |
+#ifndef _WIN32 |
| 163 |
thinButtons=true; // unsupported newlines in wxButtons under MAC! :( |
| 164 |
#endif |
| 165 |
|
| 166 |
@@ -846,11 +852,20 @@ |
| 167 |
else butSize= wxSize(70,50); |
| 168 |
|
| 169 |
for (int i=0; i<NPreset; i++) { |
| 170 |
+ printf ("presetname: %s\n", presetName[i]); |
| 171 |
+ /* |
| 172 |
preset[i]=new wxButton(this, ID_FirstPreset + i, |
| 173 |
|
| 174 |
+ thinButtons? noNewLine(wxString::FromAscii(presetName[i])):wxString::FromAscii(presetName[i]), |
| 175 |
wxDefaultPosition); //, butSize ); |
| 176 |
+ */ |
| 177 |
+ preset[i] = new wxButton(this, |
| 178 |
+ ID_FirstPreset + i, |
| 179 |
+ noNewLine(wxString::FromAscii(presetName[i])), |
| 180 |
+ wxDefaultPosition); |
| 181 |
+ |
| 182 |
preset[i]->SetMinSize(butSize); |
| 183 |
|
| 184 |
+ //if (presetName[i]==wxEmptyString) preset[i]->Show(false); |
| 185 |
+ if (!presetName[i]) preset[i]->Show(false); |
| 186 |
if (thinButtons) { |
| 187 |
if (!subSizer) subSizer=new wxBoxSizer(wxHORIZONTAL); |
| 188 |
subSizer->Add( preset[i], 1, wxALIGN_CENTER|wxEXPAND|wxALL,4 ); |
| 189 |
@@ -1016,7 +1031,7 @@ |
| 190 |
sizer->Add(5,5,0); // spacer |
| 191 |
sizer->Add(newAutoCheckBox( |
| 192 |
this,ID_SetHetatm, |
| 193 |
|
| 194 |
+ _T("Show 'HET' atoms"), |
| 195 |
&(geoSettings.showHetatm), |
| 196 |
buttonSetHetatm, textSetHetatm, |
| 197 |
AUTO_TEXT_ON_RIGHT |
| 198 |
@@ -1144,7 +1159,7 @@ |
| 199 |
|
| 200 |
sizerDB->Add(newAutoSlider( |
| 201 |
this, ID_SetFog, |
| 202 |
|
| 203 |
+ _T("Strength:"), |
| 204 |
&(cgSettings.P_fog) |
| 205 |
), 0 , wxALIGN_RIGHT ); |
| 206 |
|
| 207 |
@@ -1161,7 +1176,7 @@ |
| 208 |
|
| 209 |
sizerHA->Add(newAutoSlider( |
| 210 |
this, ID_SetHaloStr, |
| 211 |
|
| 212 |
+ _T("Strength:"), |
| 213 |
&(cgSettings.P_halo_str), |
| 214 |
sliderHaloStr, textHaloStr |
| 215 |
), 0 , wxALIGN_RIGHT ); |