analysis json data :param datas: json data
(self, datas)
| 263 | self._chart.setAxisX(xaxis, series[-1]) |
| 264 | |
| 265 | def __analysis(self, datas): |
| 266 | ''' |
| 267 | analysis json data |
| 268 | :param datas: json data |
| 269 | ''' |
| 270 | # 标题 |
| 271 | self.__setTitle(datas.get("title", None)) |
| 272 | # 抗锯齿 |
| 273 | if (datas.get("antialiasing", False) or False): |
| 274 | self.setRenderHint(QPainter.Antialiasing) |
| 275 | # 主题 |
| 276 | self._chart.setTheme(datas.get("theme", 0) or 0) |
| 277 | # 动画 |
| 278 | self.__setAnimation(datas.get("animation", None)) |
| 279 | # 背景设置 |
| 280 | self.__setBackground(datas.get("background", None)) |
| 281 | # 边距设置 |
| 282 | self.__setMargins(datas.get("margins", None)) |
| 283 | # 设置图例 |
| 284 | self.__setLegend(datas.get("legend", None)) |
| 285 | # 设置series |
| 286 | self.__setSeries(datas.get("series", None)) |
| 287 | # 自定义的x轴 |
| 288 | self.__setAxisX(datas.get("axisx", None)) |
| 289 | # 自定义的y轴 |
no test coverage detected