layout字体设置成times new roman
This commit is contained in:
7
chart.py
7
chart.py
@@ -164,6 +164,7 @@ class QuantChart:
|
|||||||
cci_chart = chart.create_subchart(
|
cci_chart = chart.create_subchart(
|
||||||
position=position, width=1, height=height, sync=True
|
position=position, width=1, height=height, sync=True
|
||||||
)
|
)
|
||||||
|
cci_chart.layout(font_family="Times New Roman")
|
||||||
cci_chart.legend(
|
cci_chart.legend(
|
||||||
visible=True, font_size=14, color="#FFFFFF", font_family="Times New Roman"
|
visible=True, font_size=14, color="#FFFFFF", font_family="Times New Roman"
|
||||||
)
|
)
|
||||||
@@ -215,6 +216,7 @@ class QuantChart:
|
|||||||
macd_chart = chart.create_subchart(
|
macd_chart = chart.create_subchart(
|
||||||
position=position, width=1, height=height, sync=True
|
position=position, width=1, height=height, sync=True
|
||||||
)
|
)
|
||||||
|
macd_chart.layout(font_family="Times New Roman")
|
||||||
macd_chart.legend(
|
macd_chart.legend(
|
||||||
visible=True, font_size=14, color="#FFFFFF", font_family="Times New Roman"
|
visible=True, font_size=14, color="#FFFFFF", font_family="Times New Roman"
|
||||||
)
|
)
|
||||||
@@ -411,12 +413,11 @@ class QuantChart:
|
|||||||
self.check_df(df)
|
self.check_df(df)
|
||||||
|
|
||||||
chart = Chart(toolbox=True, inner_height=0.8, maximize=True)
|
chart = Chart(toolbox=True, inner_height=0.8, maximize=True)
|
||||||
|
chart.layout(font_family="Times New Roman")
|
||||||
chart.topbar.textbox("symbol", symbol)
|
chart.topbar.textbox("symbol", symbol)
|
||||||
chart.topbar.textbox("name", name)
|
chart.topbar.textbox("name", name)
|
||||||
chart.topbar.textbox("timeframe", timeframe)
|
chart.topbar.textbox("timeframe", timeframe)
|
||||||
chart.legend(
|
chart.legend(visible=True, font_size=14, color="#FFFFFF")
|
||||||
visible=True, font_size=14, color="#FFFFFF", font_family="Times New Roman"
|
|
||||||
)
|
|
||||||
chart.set(df)
|
chart.set(df)
|
||||||
|
|
||||||
# 设置刚进入chart时的可见k线数量范围
|
# 设置刚进入chart时的可见k线数量范围
|
||||||
|
|||||||
Reference in New Issue
Block a user