MCPcopy Create free account
hub / github.com/agraef/pure-lang / Initialize

Method Initialize

purepad/MainFrm.cpp:285–448  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

283}
284
285void CMainFrame::Initialize()
286{
287 // get our settings
288 m_strVersion = AfxGetApp()->GetProfileString(szSettings,
289 szVersion, "");
290 m_bLogReset = AfxGetApp()->GetProfileInt(szSettings,
291 szLogReset, FALSE);
292 m_nTabStops = AfxGetApp()->GetProfileInt(szSettings,
293 szTabStops, 8*4);
294 m_nLogTabStops = AfxGetApp()->GetProfileInt(szSettings,
295 szLogTabStops, 8*4);
296 m_nHistSize = AfxGetApp()->GetProfileInt(szSettings,
297 szHistSize, 100);
298 m_nLogMaxLines = AfxGetApp()->GetProfileInt(szSettings,
299 szLogMaxLines, 500);
300#if 0
301 m_strHistFile = AfxGetApp()->GetProfileString(szSettings,
302 szHistFile, "PurePadHistory");
303#else
304 char *home = getenv("HOME");
305 if (home) {
306 char *p = strchr(home, '=');
307 if (p) home = p+1;
308 m_strHistFile = AfxGetApp()->GetProfileString(szSettings,
309 szHistFile, CString(home) + "\\PurePadHistory");
310 } else
311 m_strHistFile = AfxGetApp()->GetProfileString(szSettings,
312 szHistFile, "PurePadHistory");
313#endif
314 if (m_strVersion == "1.1") {
315 m_strQPS = AfxGetApp()->GetProfileString(szSettings,
316 szQPS, "> ");
317#if 0
318 m_strCompileCommand = AfxGetApp()->GetProfileString(szSettings,
319 szCompileCommand, "qc -n -o %s %s");
320#endif
321 m_strRunCommand = AfxGetApp()->GetProfileString(szSettings,
322 szRunCommand, "pure -i -q %s");
323 m_strDebugCommand = AfxGetApp()->GetProfileString(szSettings,
324 szDebugCommand, "pure -i -q -g %s");
325 } else {
326 // update registry entries to current version
327 m_strQPS = "> ";
328#if 0
329 m_strCompileCommand = "qc -n -o %s %s";
330#endif
331 m_strRunCommand = "pure -i -q %s";
332 m_strDebugCommand = "pure -i -q -g %s";
333 }
334 CMainFrame::m_strQPSX = LastLine(m_strQPS);
335 m_strVersion = "1.1";
336 CString app_path;
337 GetAppPath(app_path);
338 m_strAppPath = AfxGetApp()->GetProfileString(szSettings,
339 szAppPath, app_path);
340 CString tcl_path, tcl_version;
341#if 0
342 GetTclPathAndVersion(tcl_path, tcl_version);

Callers

nothing calls this directly

Calls 5

LastLineFunction · 0.85
GetAppPathFunction · 0.85
GetTclPathAndVersionFunction · 0.85
GetProfileFontFunction · 0.85
IsEmptyMethod · 0.45

Tested by

no test coverage detected