Extjs设置柱状图柱子颜色和每条柱子颜色
来源:互联网 发布:python 字符串 编辑:程序博客网 时间:2024/04/29 14:42
1、Extjs中columnchart的柱子颜色设置
只要设置chart的theme即可,官方文档中theme的定义为:
The name of the theme to be used. A theme defines the colors andother visual displays of tick marks on axis, text, title text, line colors, marker colors and styles, etc.Possible theme values are 'Base', 'Green', 'Sky', 'Red', 'Purple', 'Blue', 'Yellow' and also six category themes'Category1' to 'Category6'. Default value is 'Base'.
所以,改变柱子的颜色可以改变theme的值,如果theme中的定义的值不符合你的颜色,也可以扩展theme
var colors = ['rgb(212, 40, 40)']; Ext.define('Ext.chart.theme.Fancy', { extend: 'Ext.chart.theme.Base', constructor: function(config) { this.callParent([Ext.apply({ colors: colors }, config)]); } });
2、Extjs中columnchart的每个柱子颜色设置
首先定义柱子颜色:
var colors = ['rgb(212, 40, 40)', 'rgb(180, 216, 42)', 'rgb(43, 221, 115)', 'rgb(45, 117, 226)', 'rgb(187, 45, 222)'];然后再series中定义renderer属性的函数
function(sprite, storeItem, barAttr, i, store) { barAttr.fill = colors[i % colors.length]; return barAttr; }
- Extjs设置柱状图柱子颜色和每条柱子颜色
- 【ExtJs】柱状图,改变每条柱子的颜色
- echats 柱状图柱子颜色设定。
- JfreeChart实现柱状图的每根柱子颜色不同
- Echarts 柱状图 多条柱子 颜色 宽度 标题
- (3)Jfreechart柱状图自定义柱子颜色以及柱子的方向
- echarts改变柱状图每个柱子的颜色
- Echarts之柱状图获取点击柱子事件&自定义柱子颜色&类目轴纵向排列
- Echarts柱状图,改变柱子的颜色,后台操作
- highcharts图表组件实战经验篇:如何设置柱状图柱子立体(颜色渐变)效果类似3D效果之linearGradient和stops
- flex3柱图指定某条柱子颜色
- Highcharts做柱状图怎样样每个柱子都是不同的颜色显示
- 介绍一篇“让echarts柱状图的每个柱子显示不同的颜色”的好博客
- Echarts学习 堆叠柱状图 柱子样式颜色及透明度宽度间隔修改
- 实在无助开播求指导。extjs柱状图柱子的大小怎么设置。
- 设定JFreeChart柱子上面的颜色
- 统计图-FLASH统计图如何设计柱子颜色
- echarts-多柱子柱状图
- 【索引】AOAPC I: Beginning Algorithm Contests -- Training Guide (Rujia Liu)
- js扫雷小游戏
- firefox 新标签打开 默认页面
- Linux IPC小结
- 二叉树中路径的求解
- Extjs设置柱状图柱子颜色和每条柱子颜色
- PHP面试题
- Java多线程笔试题
- 使用scrapy爬取整站图片
- VMware 虚拟机网卡模式解析
- URI,URL,URN
- PHY管理接口(MDIO)
- csdn每次内测都搬出的测反应速度的网页小游戏
- 5求最大数---问555555的约数中最大的三位数是多少?