Skip to content
  • Halla Rempt's avatar
    Add usage logging to the buginfo dialog · caebac3e
    Halla Rempt authored
    We can now log important events to a krita.log file. It is completely
    independent of qDebug, and only meant for those actions that we know
    users often get wrong or have problems with. Right now, it logs
    creating, loading, exporting and saving a file, and switching between
    the smoothing options.
    
    The krita.log file is NOT automatically uploaded or shared or anything
    like that. The header that explains this is translated so users can
    see that for themselves.
    
    We rotate 10 sessions in the log file, so even if the user starts Krita
    a few times after having a problem, we should still be able to review
    the problematical session.
    
    The logging api is pretty simple: a static KisUsageLogger::log method
    that writes a timestamp, and a KisUsageLogger::write method that writes
    an informational line without a timestamp.
    
    Note that the logger is created and torn down in the main function:
    this means that the location is GenericDataLocation, not AppDataLocation.
    
    CCMAIL:kimageshop@kde.org
    caebac3e