/[svn]/qsampler/trunk/src/qsamplerOptions.cpp
ViewVC logotype

Diff of /qsampler/trunk/src/qsamplerOptions.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 264 by capela, Wed Sep 29 13:12:45 2004 UTC revision 605 by capela, Fri Jun 3 10:19:42 2005 UTC
# Line 1  Line 1 
1  // qsamplerOptions.cpp  // qsamplerOptions.cpp
2  //  //
3  /****************************************************************************  /****************************************************************************
4     Copyright (C) 2003-2004, rncbc aka Rui Nuno Capela. All rights reserved.     Copyright (C) 2003-2005, rncbc aka Rui Nuno Capela. All rights reserved.
5    
6     This program is free software; you can redistribute it and/or     This program is free software; you can redistribute it and/or
7     modify it under the terms of the GNU General Public License     modify it under the terms of the GNU General Public License
# Line 28  Line 28 
28    
29  #include "config.h"  #include "config.h"
30    
31    #ifdef CONFIG_LIBGIG
32    #include <gig.h>
33    #endif
34    
35    
36  //-------------------------------------------------------------------------  //-------------------------------------------------------------------------
37  // qsamplerOptions - Prototype settings structure.  // qsamplerOptions - Prototype settings structure.
# Line 46  qsamplerOptions::qsamplerOptions (void) Line 50  qsamplerOptions::qsamplerOptions (void)
50      m_settings.beginGroup("/Server");      m_settings.beginGroup("/Server");
51      sServerHost    = m_settings.readEntry("/ServerHost", "localhost");      sServerHost    = m_settings.readEntry("/ServerHost", "localhost");
52      iServerPort    = m_settings.readNumEntry("/ServerPort", 8888);      iServerPort    = m_settings.readNumEntry("/ServerPort", 8888);
53      iServerTimeout = m_settings.readNumEntry("/ServerTimeout", 500);      iServerTimeout = m_settings.readNumEntry("/ServerTimeout", 1000);
54      bServerStart   = m_settings.readBoolEntry("/ServerStart", true);      bServerStart   = m_settings.readBoolEntry("/ServerStart", true);
55      sServerCmdLine = m_settings.readEntry("/ServerCmdLine", "linuxsampler");      sServerCmdLine = m_settings.readEntry("/ServerCmdLine", "linuxsampler");
56      iStartDelay    = m_settings.readNumEntry("/StartDelay", 2);      iStartDelay    = m_settings.readNumEntry("/StartDelay", 3);
57      m_settings.endGroup();      m_settings.endGroup();
58    
59      // Load display options...      // Load display options...
60      m_settings.beginGroup("/Display");      m_settings.beginGroup("/Display");
61      sDisplayFont     = m_settings.readEntry("/DisplayFont", QString::null);      sDisplayFont     = m_settings.readEntry("/DisplayFont", QString::null);
62        bDisplayEffect   = m_settings.readBoolEntry("/DisplayEffect", true);
63      bAutoRefresh     = m_settings.readBoolEntry("/AutoRefresh", true);      bAutoRefresh     = m_settings.readBoolEntry("/AutoRefresh", true);
64      iAutoRefreshTime = m_settings.readNumEntry("/AutoRefreshTime", 1000);      iAutoRefreshTime = m_settings.readNumEntry("/AutoRefreshTime", 1000);
65      iMaxVolume       = m_settings.readNumEntry("/MaxVolume", 100);      iMaxVolume       = m_settings.readNumEntry("/MaxVolume", 100);
# Line 62  qsamplerOptions::qsamplerOptions (void) Line 67  qsamplerOptions::qsamplerOptions (void)
67      bMessagesLimit   = m_settings.readBoolEntry("/MessagesLimit", true);      bMessagesLimit   = m_settings.readBoolEntry("/MessagesLimit", true);
68      iMessagesLimitLines = m_settings.readNumEntry("/MessagesLimitLines", 1000);      iMessagesLimitLines = m_settings.readNumEntry("/MessagesLimitLines", 1000);
69      bConfirmRemove   = m_settings.readBoolEntry("/ConfirmRemove", true);      bConfirmRemove   = m_settings.readBoolEntry("/ConfirmRemove", true);
70        bKeepOnTop       = m_settings.readBoolEntry("/KeepOnTop", true);
71      bStdoutCapture   = m_settings.readBoolEntry("/StdoutCapture", true);      bStdoutCapture   = m_settings.readBoolEntry("/StdoutCapture", true);
72      bCompletePath    = m_settings.readBoolEntry("/CompletePath", true);      bCompletePath    = m_settings.readBoolEntry("/CompletePath", true);
73      iMaxRecentFiles  = m_settings.readNumEntry("/MaxRecentFiles", 5);      iMaxRecentFiles  = m_settings.readNumEntry("/MaxRecentFiles", 5);
74        bInstrumentNames = m_settings.readBoolEntry("/InstrumentNames", false);
75      m_settings.endGroup();      m_settings.endGroup();
76    
77      // And go into view options group.      // And go into view options group.
# Line 122  qsamplerOptions::~qsamplerOptions (void) Line 129  qsamplerOptions::~qsamplerOptions (void)
129      // Save display options.      // Save display options.
130      m_settings.beginGroup("/Display");      m_settings.beginGroup("/Display");
131      m_settings.writeEntry("/DisplayFont", sDisplayFont);      m_settings.writeEntry("/DisplayFont", sDisplayFont);
132        m_settings.writeEntry("/DisplayEffect", bDisplayEffect);
133      m_settings.writeEntry("/AutoRefresh", bAutoRefresh);      m_settings.writeEntry("/AutoRefresh", bAutoRefresh);
134      m_settings.writeEntry("/AutoRefreshTime", iAutoRefreshTime);      m_settings.writeEntry("/AutoRefreshTime", iAutoRefreshTime);
135      m_settings.writeEntry("/MaxVolume", iMaxVolume);      m_settings.writeEntry("/MaxVolume", iMaxVolume);
# Line 129  qsamplerOptions::~qsamplerOptions (void) Line 137  qsamplerOptions::~qsamplerOptions (void)
137      m_settings.writeEntry("/MessagesLimit", bMessagesLimit);      m_settings.writeEntry("/MessagesLimit", bMessagesLimit);
138      m_settings.writeEntry("/MessagesLimitLines", iMessagesLimitLines);      m_settings.writeEntry("/MessagesLimitLines", iMessagesLimitLines);
139      m_settings.writeEntry("/ConfirmRemove", bConfirmRemove);      m_settings.writeEntry("/ConfirmRemove", bConfirmRemove);
140        m_settings.writeEntry("/KeepOnTop", bKeepOnTop);
141      m_settings.writeEntry("/StdoutCapture", bStdoutCapture);      m_settings.writeEntry("/StdoutCapture", bStdoutCapture);
142      m_settings.writeEntry("/CompletePath", bCompletePath);      m_settings.writeEntry("/CompletePath", bCompletePath);
143      m_settings.writeEntry("/MaxRecentFiles", iMaxRecentFiles);      m_settings.writeEntry("/MaxRecentFiles", iMaxRecentFiles);
144        m_settings.writeEntry("/InstrumentNames", bInstrumentNames);
145      m_settings.endGroup();      m_settings.endGroup();
146    
147      // View options group.      // View options group.
# Line 251  bool qsamplerOptions::parse_args ( int a Line 261  bool qsamplerOptions::parse_args ( int a
261          }          }
262          else if (sArg == "-v" || sArg == "--version") {          else if (sArg == "-v" || sArg == "--version") {
263              fprintf(stderr, "Qt: %s\n", qVersion());              fprintf(stderr, "Qt: %s\n", qVersion());
264              fprintf(stderr, "liblscp: %s\n", ::lscp_client_version());  #ifdef CONFIG_LIBGIG
265                            fprintf(stderr, "%s: %s\n", gig::libraryName().c_str(), gig::libraryVersion().c_str());
266    #endif            
267                fprintf(stderr, "%s: %s\n", ::lscp_client_package(), ::lscp_client_version());
268              fprintf(stderr, "qsampler: %s\n", QSAMPLER_VERSION);              fprintf(stderr, "qsampler: %s\n", QSAMPLER_VERSION);
269              return false;              return false;
270          }          }

Legend:
Removed from v.264  
changed lines
  Added in v.605

  ViewVC Help
Powered by ViewVC