예제 #1
0
void ApplicationSettings::Private::init()
{
    albumCategoryNames.clear();
    albumCategoryNames.append(i18n("Category"));
    albumCategoryNames.append(i18n("Travel"));
    albumCategoryNames.append(i18n("Holidays"));
    albumCategoryNames.append(i18n("Friends"));
    albumCategoryNames.append(i18n("Nature"));
    albumCategoryNames.append(i18n("Party"));
    albumCategoryNames.append(i18n("Todo"));
    albumCategoryNames.append(i18n("Miscellaneous"));
    albumCategoryNames.sort();

    albumSortRole                       = ApplicationSettings::ByFolder;
    imageSortOrder                      = ImageSortSettings::SortByFileName;
    imageSorting                        = ImageSortSettings::AscendingOrder;
    imageGroupMode                      = ImageSortSettings::CategoryByAlbum;
    imageGroupSortOrder                 = ImageSortSettings::AscendingOrder;

    itemLeftClickAction                 = ApplicationSettings::ShowPreview;

    thumbnailSize                       = ThumbnailSize::Medium;
    treeThumbnailSize                   = 22;
    treeviewFont                        = QFontDatabase::systemFont(QFontDatabase::GeneralFont);
    sidebarTitleStyle                   = DMultiTabBar::ActiveIconText;

    ratingFilterCond                    = ImageFilterSettings::GreaterEqualCondition;

    showSplash                          = true;
    useTrash                            = true;
    showTrashDeleteDialog               = true;
    showPermanentDeleteDialog           = true;
    sidebarApplyDirectly                = false;
    scrollItemToCenter                  = false;

    iconShowName                        = false;
    iconShowSize                        = false;
    iconShowDate                        = true;
    iconShowModDate                     = true;
    iconShowTitle                       = true;
    iconShowComments                    = true;
    iconShowResolution                  = false;
    iconShowAspectRatio                 = false;
    iconShowTags                        = true;
    iconShowOverlays                    = true;
    iconShowFullscreen                  = true;
    iconShowRating                      = true;
    iconShowImageFormat                 = false;
    iconShowCoordinates                 = false;
    iconviewFont                        = QFontDatabase::systemFont(QFontDatabase::GeneralFont);
    toolTipsFont                        = QFontDatabase::systemFont(QFontDatabase::GeneralFont);
    showToolTips                        = false;
    tooltipShowFileName                 = true;
    tooltipShowFileDate                 = false;
    tooltipShowFileSize                 = false;
    tooltipShowImageType                = false;
    tooltipShowImageDim                 = true;
    tooltipShowImageAR                  = true;
    tooltipShowPhotoMake                = true;
    tooltipShowPhotoDate                = true;
    tooltipShowPhotoFocal               = true;
    tooltipShowPhotoExpo                = true;
    tooltipShowPhotoMode                = true;
    tooltipShowPhotoFlash               = false;
    tooltipShowPhotoWb                  = false;
    tooltipShowAlbumName                = false;
    tooltipShowTitles                   = false;
    tooltipShowComments                 = true;
    tooltipShowTags                     = true;
    tooltipShowLabelRating              = true;

    tooltipShowVideoAspectRatio         = true;
    tooltipShowVideoAudioBitRate        = true;
    tooltipShowVideoAudioChannelType    = true;
    tooltipShowVideoAudioCompressor     = true;
    tooltipShowVideoDuration            = true;
    tooltipShowVideoFrameRate           = true;
    tooltipShowVideoVideoCodec          = true;

    showAlbumToolTips                   = false;
    tooltipShowAlbumTitle               = true;
    tooltipShowAlbumDate                = true;
    tooltipShowAlbumCollection          = true;
    tooltipShowAlbumCategory            = true;
    tooltipShowAlbumCaption             = true;
    tooltipShowAlbumPreview             = false;

    previewShowIcons                    = true;
    showThumbbar                        = true;

    recursiveAlbums                     = false;
    recursiveTags                       = true;

    showFolderTreeViewItemsCount        = false;

    syncToDigikam                       = false;
    syncToBaloo                         = false;
    albumSortChanged                    = false;

    faceDetectionAccuracy               = 0.8;

    stringComparisonType                = ApplicationSettings::Natural;
    applicationStyle                    = qApp->style()->objectName();
    iconTheme                           = QString();

    q->connect(q, SIGNAL(balooSettingsChanged()),
               q, SLOT(applyBalooSettings()));
}
예제 #2
0
void ApplicationSettings::Private::init()
{
    albumCategoryNames.clear();
    albumCategoryNames.append(i18n("Category"));
    albumCategoryNames.append(i18n("Travel"));
    albumCategoryNames.append(i18n("Holidays"));
    albumCategoryNames.append(i18n("Friends"));
    albumCategoryNames.append(i18n("Nature"));
    albumCategoryNames.append(i18n("Party"));
    albumCategoryNames.append(i18n("Todo"));
    albumCategoryNames.append(i18n("Miscellaneous"));
    albumCategoryNames.sort();

    albumSortRole                        = ApplicationSettings::ByFolder;
    imageSortOrder                       = ItemSortSettings::SortByFileName;
    imageSorting                         = ItemSortSettings::AscendingOrder;
    imageSeparationMode                  = ItemSortSettings::CategoryByAlbum;
    imageSeparationSortOrder             = ItemSortSettings::AscendingOrder;

    itemLeftClickAction                  = ApplicationSettings::ShowPreview;

    thumbnailSize                        = ThumbnailSize::Medium;
    treeThumbnailSize                    = 22;
    treeviewFont                         = QFontDatabase::systemFont(QFontDatabase::GeneralFont);
    sidebarTitleStyle                    = DMultiTabBar::AllIconsText;

    ratingFilterCond                     = ItemFilterSettings::GreaterEqualCondition;

    showSplash                           = true;
    useTrash                             = true;
    showTrashDeleteDialog                = true;
    showPermanentDeleteDialog            = true;
    sidebarApplyDirectly                 = false;
    useNativeFileDialog                  = false;
    drawFramesToGrouped                  = true;
    scrollItemToCenter                   = false;
    showOnlyPersonTagsInPeopleSidebar    = false;

    iconShowName                         = false;
    iconShowSize                         = false;
    iconShowDate                         = false;
    iconShowModDate                      = false;
    iconShowTitle                        = false;
    iconShowComments                     = false;
    iconShowResolution                   = false;
    iconShowAspectRatio                  = false;
    iconShowTags                         = true;
    iconShowOverlays                     = true;
    iconShowFullscreen                   = true;
    iconShowRating                       = true;
    iconShowImageFormat                  = true;
    iconShowCoordinates                  = true;
    iconviewFont                         = QFontDatabase::systemFont(QFontDatabase::GeneralFont);
    toolTipsFont                         = QFontDatabase::systemFont(QFontDatabase::GeneralFont);
    showToolTips                         = false;
    tooltipShowFileName                  = true;
    tooltipShowFileDate                  = false;
    tooltipShowFileSize                  = false;
    tooltipShowImageType                 = false;
    tooltipShowImageDim                  = true;
    tooltipShowImageAR                   = true;
    tooltipShowPhotoMake                 = true;
    tooltipShowPhotoLens                 = true;
    tooltipShowPhotoDate                 = true;
    tooltipShowPhotoFocal                = true;
    tooltipShowPhotoExpo                 = true;
    tooltipShowPhotoMode                 = true;
    tooltipShowPhotoFlash                = false;
    tooltipShowPhotoWb                   = false;
    tooltipShowAlbumName                 = false;
    tooltipShowTitles                    = false;
    tooltipShowComments                  = true;
    tooltipShowTags                      = true;
    tooltipShowLabelRating               = true;

    tooltipShowVideoAspectRatio          = true;
    tooltipShowVideoAudioBitRate         = true;
    tooltipShowVideoAudioChannelType     = true;
    tooltipShowVideoAudioCodec           = true;
    tooltipShowVideoDuration             = true;
    tooltipShowVideoFrameRate            = true;
    tooltipShowVideoVideoCodec           = true;

    showAlbumToolTips                    = false;
    tooltipShowAlbumTitle                = true;
    tooltipShowAlbumDate                 = true;
    tooltipShowAlbumCollection           = true;
    tooltipShowAlbumCategory             = true;
    tooltipShowAlbumCaption              = true;
    tooltipShowAlbumPreview              = false;

    previewShowIcons                     = true;
    showThumbbar                         = true;

    recursiveAlbums                      = false;
    recursiveTags                        = true;

    showFolderTreeViewItemsCount         = false;

    syncToDigikam                        = false;
    syncToBaloo                          = false;
    albumSortChanged                     = false;

    faceDetectionAccuracy                = 0.8;

    minimumSimilarityBound               = 40;
    duplicatesSearchLastMinSimilarity    = 90;
    duplicatesSearchLastMaxSimilarity    = 100;
    duplicatesSearchLastAlbumTagRelation = 0;
    duplicatesSearchLastRestrictions     = 0;

    scanAtStart                          = true;
    cleanAtStart                         = true;
    databaseDirSetAtCmd                  = false;
    stringComparisonType                 = ApplicationSettings::Natural;

    applicationStyle                     = qApp->style()->objectName();
    applicationIcon                      = QString();
    applicationFont                      = QFontDatabase::systemFont(QFontDatabase::GeneralFont);

    for (int i = 0 ; i != ApplicationSettings::Unspecified ; ++i)
    {
        groupingOperateOnAll.insert((ApplicationSettings::OperationType)i,
                                    ApplicationSettings::Ask);
    }

    q->connect(q, SIGNAL(balooSettingsChanged()),
               q, SLOT(applyBalooSettings()));
}