Exemple #1
0
        if GS(parsed_args_v[u'log-interval']).isnumeric():
            SetLogWindowRefreshInterval(int(parsed_args_v[u'log-interval']))

    Debreate.SetLogWindow(LogWindow(Debreate, Logger.GetLogFile()))

if conf_values[u'maximize']:
    Debreate.Maximize()

elif conf_values[u'center']:
    from system.display import CenterOnPrimaryDisplay

    # NOTE: May be a few pixels off
    CenterOnPrimaryDisplay(Debreate)

# Set project compression
Debreate.SetCompression(GetCompressionId(conf_values[u'compression']))

working_dir = conf_values[u'workingdir']

if parsed_path:
    project_file = parsed_path
    Logger.Debug(script_name,
                 GT(u'Opening project from argument: {}').format(project_file))

    if Debreate.ProjectOpen(project_file):
        working_dir = os.path.dirname(project_file)

# Set working directory (do not call os.chdir in case of opening project)
ChangeWorkingDirectory(working_dir)

Debreate.Show(True)