tdesktop/Telegram/SourceFiles/settings/settings.style

386 lines
13 KiB
Plaintext

/*
This file is part of Telegram Desktop,
the official desktop application for the Telegram messaging service.
For license and copyright information please follow this link:
https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
*/
using "ui/basic.style";
using "ui/widgets/widgets.style";
using "info/info.style";
using "boxes/boxes.style";
settingsButton: SettingsButton(infoProfileButton) {
style: boxTextStyle;
padding: margins(60px, 10px, 22px, 10px);
iconLeft: 20px;
}
settingsButtonNoIcon: SettingsButton(settingsButton) {
padding: margins(22px, 10px, 22px, 8px);
}
settingsAttentionButton: SettingsButton(settingsButtonNoIcon) {
textFg: attentionButtonFg;
textFgOver: attentionButtonFgOver;
}
settingsOptionDisabled: SettingsButton(settingsButtonNoIcon) {
textFg: windowSubTextFg;
textFgOver: windowSubTextFg;
textBg: windowBg;
textBgOver: windowBg;
toggleOver: infoProfileToggle;
}
settingsSectionSkip: 6px;
settingsSeparatorPadding: margins(22px, infoProfileSkip, 0px, infoProfileSkip);
settingsButtonRightSkip: 23px;
settingsScalePadding: margins(63px, 7px, 21px, 4px);
settingsBigScalePadding: margins(21px, 7px, 21px, 4px);
settingsSlider: SettingsSlider(defaultSettingsSlider) {
barFg: windowBgOver;
labelFg: windowSubTextFg;
labelFgActive: windowActiveTextFg;
}
settingsUpdateToggle: SettingsButton(settingsButtonNoIcon) {
height: 40px;
padding: margins(22px, 8px, 22px, 8px);
}
settingsUpdateState: FlatLabel(defaultFlatLabel) {
textFg: windowSubTextFg;
}
settingsUpdate: SettingsButton(infoMainButton, settingsButtonNoIcon) {
}
settingsUpdateStatePosition: point(22px, 29px);
settingsDividerLabelPadding: margins(22px, 8px, 22px, 16px);
settingsIconAccount: icon {{ "settings/account", settingsIconFg }};
settingsIconNotifications: icon {{ "settings/notifications", settingsIconFg }};
settingsIconChat: icon {{ "settings/chat", settingsIconFg }};
settingsIconFolders: icon {{ "settings/folders", settingsIconFg }};
settingsIconGeneral: icon {{ "settings/advanced", settingsIconFg }};
settingsIconLock: icon {{ "settings/lock", settingsIconFg }};
settingsIconLanguage: icon {{ "settings/language", settingsIconFg }};
settingsIconInterfaceScale: icon {{ "settings/interface_scale", settingsIconFg }};
settingsIconFaq: icon {{ "settings/faq", settingsIconFg }};
settingsIconCalls: icon {{ "settings/calls", settingsIconFg }};
settingsIconAskQuestion: icon {{ "settings/ask_question", settingsIconFg }};
settingsIconTips: icon {{ "settings/tips", settingsIconFg }};
settingsIconStickers: icon {{ "settings/stickers", settingsIconFg }};
settingsIconEmoji: icon {{ "settings/emoji", settingsIconFg }};
settingsIconThemes: icon {{ "settings/palette", settingsIconFg }};
settingsIconGroup: icon {{ "settings/group", settingsIconFg }};
settingsIconChannel: icon {{ "settings/channel", settingsIconFg }};
settingsIconUser: icon {{ "settings/user", settingsIconFg }};
settingsIconSavedMessages: icon {{ "settings/saved_messages", settingsIconFg }};
settingsIconKey: icon {{ "settings/key", settingsIconFg }};
settingsIconReload: icon {{ "settings/reload", settingsIconFg }};
settingsIconNight: icon {{ "settings/night", settingsIconFg }};
settingsIconSettings: icon {{ "settings/settings", settingsIconFg }};
settingsIconArchive: icon {{ "settings/archive", settingsIconFg }};
settingsIconPlus: icon {{ "settings/plus", settingsIconFg }};
settingsIconMinus: icon {{ "settings/minus", settingsIconFg }};
settingsIconTimer: icon {{ "settings/timer", settingsIconFg }};
settingsIconLaptop: icon {{ "settings/laptop", settingsIconFg }};
settingsIconArrows: icon {{ "settings/arrows", settingsIconFg }};
settingsIconOnline: icon {{ "settings/online", settingsIconFg }};
settingsIconVideoCalls: icon {{ "settings/video_calls", settingsIconFg }};
settingsIconEmail: icon {{ "settings/email", settingsIconFg }};
settingsIconForward: icon {{ "settings/forward", settingsIconFg }};
settingsIconSound: icon {{ "settings/sound", settingsIconFg }};
settingsIconDock: icon {{ "settings/dock", settingsIconFg }};
settingsIconPosition: icon {{ "settings/position", settingsIconFg }};
settingsIconPin: icon {{ "settings/pin", settingsIconFg }};
settingsIconDownload: icon {{ "settings/download", settingsIconFg }};
settingsIconMention: icon {{ "settings/mention", settingsIconFg }};
settingsCheckbox: Checkbox(defaultBoxCheckbox) {
textPosition: point(15px, 1px);
}
settingsCheckboxPadding: margins(22px, 10px, 10px, 10px);
settingsLink: boxLinkButton;
settingsAdvancedNotificationsPadding: margins(22px, 20px, 10px, 10px);
settingsLinkLabel: defaultFlatLabel;
settingsCheckboxesSkip: 12px;
settingsSendType: settingsCheckbox;
settingsSendTypePadding: margins(22px, 5px, 10px, 5px);
settingsSendTypeSkip: 5px;
settingsBackgroundThumb: 76px;
settingsThumbSkip: 16px;
settingsSubsectionTitle: FlatLabel(defaultFlatLabel) {
style: TextStyle(semiboldTextStyle) {
font: font(boxFontSize semibold);
linkFont: font(boxFontSize semibold);
linkFontOver: font(boxFontSize semibold underline);
}
textFg: windowActiveTextFg;
minWidth: 240px;
}
settingsSubsectionTitleRight: FlatLabel(settingsSubsectionTitle) {
minWidth: 0px;
}
settingsSubsectionTitlePadding: margins(22px, 7px, 10px, 9px);
settingsBackgroundPadding: margins(22px, 11px, 10px, 12px);
settingsTileSkip: 15px;
settingsFromGalleryTop: 2px;
settingsFromFileTop: 14px;
settingsPrivacyOption: Checkbox(settingsCheckbox) {
textPosition: point(13px, 1px);
}
settingsPrivacySecurityPadding: 12px;
settingsPrivacySkip: 14px;
settingsPrivacySkipTop: 4px;
settingsCloudPasswordLabel: FlatLabel(defaultFlatLabel) {
textFg: windowSubTextFg;
style: boxTextStyle;
maxHeight: 20px;
}
settingsCloudPasswordLabelPadding: margins(22px, 8px, 10px, 8px);
settingsInfoPhotoHeight: 161px;
settingsInfoPhotoSize: 100px;
settingsInfoPhoto: UserpicButton(defaultUserpicButton) {
size: size(settingsInfoPhotoSize, settingsInfoPhotoSize);
photoSize: settingsInfoPhotoSize;
}
settingsInfoUploadSize: 32px;
settingsInfoUpload: UserpicButton(defaultUserpicButton) {
size: size(settingsInfoUploadSize, settingsInfoUploadSize);
photoSize: settingsInfoUploadSize;
changeIcon: icon {{ "settings/photo", activeButtonFg }};
changeIconPosition: point(4px, 4px);
}
settingsInfoUploadBorder: 2px;
settingsInfoPhotoTop: 0px;
settingsInfoPhotoSkip: 7px;
settingsInfoNameSkip: -1px;
settingsInfoUploadLeft: 6px;
settingsBio: InputField(defaultInputField) {
textBg: transparent;
textMargins: margins(0px, 7px, 0px, 13px);
placeholderFg: placeholderFg;
placeholderFgActive: placeholderFgActive;
placeholderFgError: placeholderFgActive;
placeholderMargins: margins(2px, 0px, 2px, 0px);
placeholderScale: 0.;
placeholderFont: normalFont;
border: 0px;
borderActive: 0px;
heightMin: 32px;
font: boxTextFont;
}
settingsInfoAfterSkip: 14px;
settingsBioMargins: margins(22px, 6px, 22px, 4px);
settingsBioCountdown: FlatLabel(defaultFlatLabel) {
style: boxTextStyle;
textFg: windowSubTextFg;
}
settingsCoverName: FlatLabel(defaultFlatLabel) {
maxHeight: 24px;
style: TextStyle(defaultTextStyle) {
font: font(17px semibold);
linkFont: font(17px semibold);
linkFontOver: font(17px semibold);
}
}
settingsCoverStatus: FlatLabel(defaultFlatLabel) {
textFg: windowSubTextFg;
}
settingsPrivacyEditLabelPadding: margins(22px, 11px, 22px, 11px);
settingsThemesTopSkip: 10px;
settingsThemesBottomSkip: 8px;
settingsTheme: Checkbox(defaultCheckbox) {
textFg: windowSubTextFg;
textFgActive: windowActiveTextFg;
width: 80px;
margin: margins(0px, 0px, 0px, 0px);
textPosition: point(0px, 99px);
checkPosition: point(0px, 0px);
style: defaultTextStyle;
disabledOpacity: 0.5;
}
settingsThemePreviewSize: size(80px, 92px);
settingsThemeBubbleSize: size(40px, 14px);
settingsThemeBubbleRadius: 2px;
settingsThemeBubblePosition: point(6px, 8px);
settingsThemeBubbleSkip: 6px;
settingsThemeRadioBottom: 12px;
settingsThemeMinSkip: 4px;
settingsThemeNotSupportedBg: windowBgOver;
settingsThemeNotSupportedIcon: icon {{ "theme_preview", menuIconFg }};
autoDownloadLimitButton: SettingsButton(settingsButtonNoIcon) {
padding: margins(22px, 10px, 22px, 0px);
}
settingsAudioVolumeSlider: MediaSlider(defaultContinuousSlider) {
seekSize: size(15px, 15px);
}
settingsAudioVolumeSliderPadding: margins(22px, 5px, 20px, 10px);
settingsAudioVolumeLabel: LabelSimple(defaultLabelSimple) {
font: boxTextFont;
textFg: windowBoldFg;
}
settingsAudioVolumeLabelPadding: margins(22px, 11px, 22px, 11px);
settingsLevelMeterPadding: margins(22px, 10px, 20px, 10px);
settingsForwardPrivacyPadding: 10px;
settingsForwardPrivacyArrowSkip: 32px;
settingsForwardPrivacyArrowSize: 7px;
settingsForwardPrivacyTooltipPadding: margins(12px, 7px, 12px, 7px);
settingsAccentColorSize: 24px;
settingsAccentColorSkip: 4px;
settingsAccentColorLine: 3px;
settingsFilterIconSkip: 68px;
settingsFilterIconLeft: 17px;
settingsDeviceName: InputField(defaultInputField) {
textBg: transparent;
textMargins: margins(1px, 3px, 1px, 4px);
placeholderFg: placeholderFg;
placeholderFgActive: placeholderFgActive;
placeholderFgError: placeholderFgActive;
placeholderMargins: margins(1px, 0px, 1px, 0px);
placeholderScale: 0.;
placeholderFont: normalFont;
heightMin: 29px;
font: boxTextFont;
}
dictionariesSectionButton: SettingsButton(settingsUpdateToggle) {
style: TextStyle(defaultTextStyle) {
font: font(14px semibold);
linkFont: font(14px semibold);
linkFontOver: font(14px semibold underline);
}
}
sessionsScroll: boxScroll;
sessionsHeight: 350px;
sessionLocationTop: 54px;
sessionCurrentSkip: 8px;
sessionSubtitleSkip: 14px;
sessionLocationFg: windowSubTextFg;
sessionInfoFg: windowSubTextFg;
sessionTerminateTop: 9px;
sessionTerminateSkip: 12px;
sessionTerminate: IconButton {
width: 20px;
height: 20px;
icon: smallCloseIcon;
iconOver: smallCloseIconOver;
iconPosition: point(5px, 5px);
rippleAreaPosition: point(0px, 0px);
rippleAreaSize: 20px;
ripple: RippleAnimation(defaultRippleAnimation) {
color: windowBgOver;
}
}
sessionIconWindows: icon{{ "settings/devices/device_desktop_win", historyPeerUserpicFg }};
sessionIconMac: icon{{ "settings/devices/device_desktop_mac", historyPeerUserpicFg }};
sessionIconUbuntu: icon{{ "settings/devices/device_linux_ubuntu", historyPeerUserpicFg }};
sessionIconLinux: icon{{ "settings/devices/device_linux", historyPeerUserpicFg }};
sessionIconiPhone: icon{{ "settings/devices/device_phone_ios", historyPeerUserpicFg }};
sessionIconiPad: icon{{ "settings/devices/device_tablet_ios", historyPeerUserpicFg }};
sessionIconAndroid: icon{{ "settings/devices/device_phone_android", historyPeerUserpicFg }};
sessionIconWeb: icon{{ "settings/devices/device_web_other", historyPeerUserpicFg }};
sessionIconChrome: icon{{ "settings/devices/device_web_chrome", historyPeerUserpicFg }};
sessionIconEdge: icon{{ "settings/devices/device_web_edge", historyPeerUserpicFg }};
sessionIconFirefox: icon{{ "settings/devices/device_web_firefox", historyPeerUserpicFg }};
sessionIconSafari: icon{{ "settings/devices/device_web_safari", historyPeerUserpicFg }};
sessionIconOther: icon{{ "settings/devices/device_other", historyPeerUserpicFg }};
sessionBigUserpicSize: 70px;
sessionBigLottieSize: 52px;
sessionBigIconOther: icon{{ "settings/devices/device_other_large", historyPeerUserpicFg }};
sessionBigIconWeb: icon{{ "settings/devices/device_web_other_large", historyPeerUserpicFg }};
sessionBigCoverPadding: margins(0px, 18px, 0px, 7px);
sessionBigName: FlatLabel(defaultFlatLabel) {
textFg: boxTitleFg;
maxHeight: 29px;
style: TextStyle(defaultTextStyle) {
font: font(20px semibold);
linkFont: font(20px semibold);
linkFontOver: font(20px semibold underline);
}
align: align(top);
}
sessionDateLabel: FlatLabel(defaultFlatLabel) {
textFg: windowSubTextFg;
align: align(top);
}
sessionDateSkip: 19px;
sessionValuePadding: margins(0px, 5px, 0px, 2px);
sessionValueLabel: FlatLabel(defaultFlatLabel) {
textFg: windowSubTextFg;
}
sessionValueSkip: 8px;
sessionListItem: PeerListItem(defaultPeerListItem) {
button: OutlineButton(defaultPeerListButton) {
font: normalFont;
padding: margins(11px, 5px, 11px, 5px);
}
height: 84px;
photoPosition: point(21px, 10px);
nameStyle: TextStyle(defaultTextStyle) {
font: msgNameFont;
}
namePosition: point(78px, 11px);
statusPosition: point(78px, 32px);
photoSize: 42px;
statusFg: boxTextFg;
statusFgOver: boxTextFg;
}
sessionList: PeerList(defaultPeerList) {
item: sessionListItem;
padding: margins(0px, 4px, 0px, 0px);
}
settingsPhotoLeft: 22px;
settingsPhotoTop: 8px;
settingsPhotoBottom: 16px;
settingsNameLeft: 112px;
settingsNameTop: 12px;
settingsPhoneLeft: settingsNameLeft;
settingsPhoneTop: 37px;
settingsUsernameLeft: settingsNameLeft;
settingsUsernameTop: 58px;
settingsPeerToPeerSkip: 9px;
settingsIconRadius: 6px;
settingsReactionSize: 50px;
settingsReactionRightSkip: -10px;
settingsReactionCornerSize: size(28px, 22px);
settingsReactionCornerSkip: point(11px, -6px);
settingsReactionMessageSize: 36px;
notifyPreviewMargins: margins(40px, 20px, 40px, 58px);
notifyPreviewUserpicSize: 36px;
notifyPreviewUserpicPosition: point(14px, 11px);
notifyPreviewTitlePosition: point(64px, 9px);
notifyPreviewTextPosition: point(64px, 30px);
notifyPreviewChecksSkip: 12px;
notifyPreviewBottomSkip: 9px;