Files
mt5-tools/__pycache__/view_settings.cpython-314.pyc
T

77 lines
12 KiB
Plaintext
Raw Normal View History

2026-04-12 18:25:46 +10:00
+
¾ÞiT#ãóbRt^RIt^RIt^RIt]P
P
]P
P]P
P] 44R4t
]P
P
]
R4t RRRRRR R
R R R
RRR/RRRRRR RR RR
RRR//t RRlt
RRltRRltRtRtR#)uW
view_settings.py
================
Settings page — theme, custom colours, font size.
Nz
.streamlitz config.tomlÚDarkÚbaseÚdarkÚ primaryColorú#7c6af7ÚbackgroundColorú#0e1117ÚsecondaryBackgroundColorú#1a1f2eÚ textColorú#fafafaÚfontú
sans serifÚLightÚlightz#2E75B6z#ffffffz#f0f2f6z#1a1a1acó$V^8„dQhR\/#)éÚreturn©Údict)Úformats"Ú%C:\Users\pc\MT5Tools\view_settings.pyÚ __annotate__r!s÷$”dñcó¸\PP\4'g\ \
R,4#\
\4P4p/pRF>p\P!VR,V4pV'gK+VP^4W&K@ /\
R,CVC# \d\ \
R,4u#i;i)z7Read .streamlit/config.toml, return dict of theme keys.rz\s*=\s*"([^"]*)")rrrr r r
) ÚosÚpathÚisfileÚ CONFIG_FILErÚTHEMESÚopenÚreadÚreÚsearchÚgroupÚ Exception)ÚtextÚfoundÚkeyÚms rÚ _read_configr*!s­ä
7‰7>‰>œ+× ”F˜6•NÓ
”[Ó!×(ˆØˆóCˆCä— ’ ˜#Ð 3Õ3°TÓ:ˆA߉qØŸW™W Q›Z
ñ Cð
+”&˜•.Ð* *øÜ ô”F˜6•NÓ$úsÁAB5Â
'B5Â5!CÃCcó$V^8„dQhR\/#)rÚthemer)rs"rrr2s÷ñœñrcó0\P!\RR7R.pVP4Fwr#VP V RV R24K \ \ R4;_uu_4pVPV4RRR4R# +'giR#;i)T)Úexist_okz[theme]
z = "z"
ÚwN)rÚmakedirsÚ
CONFIG_DIRÚitemsÚappendr rÚ
writelines)r,ÚlinesÚfs& rÚ
_write_configr92sl܇KK”
 
ˆM€EØ
ˆØ
˜s˜$˜q˜c Ðä
Œk˜3× Ô  1Ø ÷
× × Ò ús Á(B B có0V^8„dQhR\R\/#)rÚcfgr)rÚbool)rs"rrr;s÷ñ”DðœTñrcóüa\P4Fbp\;QJd-V3RlVP44F 'dK RM" RM!V3RlVP444'gKaR# R#)zBReturn True if the saved config differs from both standard themes.c3óP<"TFwrSPV4V8HxK R#5i)N)Úget)Ú.0r6r7r;s& €rÚ <genexpr>Ú_is_custom.<locals>.<genexpr>>søéÐ5©9¡4 1ˆsw‰wqz˜«9ùsƒ#&FT)rÚvaluesÚallr2)r;Útsf rÚ
_is_customrF;sHø€ä
]‰]Ž_ˆß 5¨1¯7©7¬9Ó533Š3Ô5¨1¯7©7¬9Ó ññ rc
óØR^R^R^/pVP\PPRR4^4pV^8”d+\P!RV RV RV RV R V R
2 R R 7R
#R
#)z;Call from app.py on every page to apply font size globally.ÚNormalú Large (+2px)úExtra Large (+4px)Ú st_font_sizezD<style>
html, body, [class*="css"] { font-size: calc(1rem + z¸px) !important; }
2026-04-12 18:25:46 +10:00
.stMarkdown p, .stMarkdown li, .stCaption, label,
.stMetric label, .stMetric div[data-testid="metric-container"] {
2026-04-12 18:25:46 +10:00
font-size: calc(1rem + z@px) !important;
}
h1 { font-size: calc(2rem + z8px) !important; }
h2 { font-size: calc(1.5rem + z9px) !important; }
h3 { font-size: calc(1.25rem + z"px) !important; }
</style>T©Úunsafe_allow_htmlN)r?ÚstÚ
session_stateÚmarkdown)Ú _size_mapÚ_deltas rÚinject_theme_cssrSCs”à˜1˜n¨aÐ1EÀqÐI€IØ
œb×.×2°>À8ÓLÈaÓP€FØ
„zÜ
Š ð>Ø>D¸F%+ ,(à(. 0(Ø(. 0)Ø)/¨ð1ð ð(,÷rcóª \P!R4\P!R4\4p\ V4'dRpMVP R4R8XdRpMRp.RTOp\P !RTRRW9dVPV4M^R 7pVRU9dh\P!R
V R 2R R
R7'dE\\V,4\P!V R24\P!4VR8XE\P!R4\P!R4\P!^4wrEpV;_uu_4\P !RVP RR4RRR7pRRR4V;_uu_4\P !RVP RR4RR7p\P !RVP RR 4R!R7p RRR4T;_uu_4\P !R"VP R#R$4R%R7p
\P"!R&.RVO.RVOPVP R(R'44R)R*7p \P !R+R,R.RR-VP RR,4R,8Xd^M^R.R/7p RRR4\P!R04\P!^4wrÞppV
XR13VX R23VXR33VX
R433F$wpppVPR5V R6V R7V R82RR97K& \P!R:4\P!^^.4wppVPR;R R<R7'dD\RX RVRVRV R#V
R(X /4\P!R=4\P!4VPR?R@RA7'dB\\R,4\P!RB4\P!4MVRU9d\P!RC4\P(!RD4;_uu_4\P*!\,4\.P0P3\,4'd5\P*!\5\,4P74RERF7M\P!RG4RRR4\P8!4\P!RH4\P!RI4\P !RJ.RWORRKRL7\;4\P8!4\P!RM4\P!RN4\P!RO4\P*!RPRQRF7\P!RR4\P*!RSRQRF7R# +'giELP;i +'giELÿ;i +'giELc;i \$d%p\P&!R>T 24Rp?EL˜Rp?ii;i +'giEL…;i)XÚSettingsÚThemeÚCustomrrrr
st_theme_pick)Ú
horizontalr(ÚindexzApply z ThemeÚprimaryÚ
st_apply_base)Útyper(u theme applied — reloading...z:Customise colours below then click **Apply Custom Theme**.z---z
Accent colourrrÚ
st_primaryzButtons, links, highlights)Úvaluer(ÚhelpNzPage backgroundrrÚst_bg)r_r(zSidebar / widget backgroundr r
Ú
st_sidebar_bgz Text colourr r Úst_textÚFontrr
Úst_font)rZr(ÚBaserÚst_custom_basez5Underlying dark or light base for your custom colours)rYr(rZr`z **Preview**zPage BGz
Sidebar BGÚAccentÚTextz<div style="background:zn;padding:14px 8px;border-radius:6px;text-align:center;font-size:12px;border:1px solid rgba(128,128,128,0.25)">z!<br><code style="font-size:10px">z
</code></div>rLÚzApply Custom ThemeÚst_applyu#Custom theme saved — reloading...zCould not write config: zDiscard / Reset to DarkÚst_reset)r(uReset to Dark — reloading...z/Select **Custom** to adjust individual colours.z Config fileÚtoml)Úlanguageu.No config.toml yet — created on first Apply.z Text Sizeu:Applies immediately across all pages — no reload needed.z Text sizerK)rYr(ÚAboutuZ