auto | : | | 默认值。浏览器根据当前情况自动确定鼠标光标类型。 |
all-scroll | : | IE6.0 | 有上下左右四个箭头,中间有一个圆点的光标。用于标示页面可以向上下左右任何方向滚动。 |
col-resize | : | IE6.0 | 有左右两个箭头,中间由竖线分隔开的光标。用于标示项目或标题栏可以被水平改变尺寸。 |
crosshair | : | | 简单的十字线光标。 |
default | : | | 客户端平台的默认光标。通常是一个箭头。 |
hand | : | | 竖起一只手指的手形光标。就像通常用户将光标移到超链接上时那样。 |
move | : | | 十字箭头光标。用于标示对象可被移动。 |
help | : | | 带有问号标记的箭头。用于标示有帮助信息存在。 |
no-drop | : | IE6.0 | 带有一个被斜线贯穿的圆圈的手形光标。用于标示被拖起的对象不允许在光标的当前位置被放下。 |
not-allowed | : | IE6.0 | 禁止标记(一个被斜线贯穿的圆圈)光标。用于标示请求的操作不允许被执行。 |
pointer | : | IE6.0 | 和 hand 一样。竖起一只手指的手形光标。就像通常用户将光标移到超链接上时那样。 |
progress | : | IE6.0 | 带有沙漏标记的箭头光标。用于标示一个进程正在后台运行。 |
row-resize | : | IE6.0 | 有上下两个箭头,中间由横线分隔开的光标。用于标示项目或标题栏可以被垂直改变尺寸。 |
text | : | | 用于标示可编辑的水平文本的光标。通常是大写字母 I 的形状。 |
vertical-text | : | IE6.0 | 用于标示可编辑的垂直文本的光标。通常是大写字母 I 旋转90度的形状。 |
wait | : | | 用于标示程序忙用户需要等待的光标。通常是沙漏或手表的形状。 |
*-resize | : | | 用于标示对象可被改变尺寸方向的箭头光标。w-resize | s-resize | n-resize | e-resize | ne-resize | sw-resize | se-resize | nw-resize |
url ( url ) | : | IE6.0 | 用户自定义光标。使用绝对或相对 url 地址指定光标文件(后缀为 .cur 或者 .ani )。 |
设置或检索在对象上移动的鼠标指针采用的光标形状。
此属性的值可以是多个,其间用逗号分隔。假如第一个值不可以被客户端系统理解或所指定的光标无法找到及显示,则第二个值将被尝试使用。依此类推。假如全部值都不可用的话,则此属性不会发生作用。光标不会被改变。
此属性对于currentStyle对象而言是只读的。对于其他对象而言是可读写的。
对应的脚本特性为
cursor 。
把你的光标放到相应文字上鼠标显示效果 | 注意光标的实际效果依赖于用户的系统设置,与你在这里看到的效果不一定完全一致。 |
cursor: auto; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTEG_7U-1JZcibr-VOQ9iKep6B5YhwoADHbbdJu_rj-JIt6emy9KMxYAuolJXeJvNRs.jpg)
| 自动 | The browser sets a cursor 浏览器设置一个游标 |
cursor:all-scroll; | | 上下左右任何方向滚动 | IE6.0有上下左右四个箭头,中间有一个圆点的光标。用于标示页面可以向上下左右任何方向滚动。 |
cursor: crosshair; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTF8Q9_pFlVxvhxZDCasK8xphWZ9twh8j8YMluZ0Zxq2Us1sIzJGOqdcGiwULtk1iAw.jpg)
| 十字准心 | The cursor render as a crosshair 游标表现为十字准线 |
cursor: pointer; cursor: hand; 写两个是为了照顾IE5,它只认hand。 | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTGiNBgSkJccnnLd12YqQ5BE145RrPXj99JiVX5EBTdZyGrdFEsM3eAz640bWR1iYSE.jpg)
| 手 | The cursor render as a pointer (a hand) that indicates a link 游标以暗示(手指)的形式来表明有一个连接 |
cursor: wait; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTGZZlRkatCDYnAXPeykkWJJxBto42sC_cnNhtgPVpXjp19yZGAeMuMtKFxdhQdJT5c.jpg)
| 等待/沙漏 | The cursor indicates that the program is busy (often a watch or an hourglass) 游标暗示当前程序正忙(一般为一块表或是一个沙漏) |
cursor: help; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTF-3ovkR5EAUOTOHY88A5OYwykDXMKpz4IaskrXXs_XnhFJ_jcaLcSuXGRBf__gpDg.jpg)
| 帮助 | The cursor indicates that help is available (often a question mark or a balloon) 游标暗示当前位置可得到帮助(一般为问号或是气球) |
cursor: no-drop; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTEuYC1ruGwHpz7EOASHBXdq2s0dJTvVvRJxNlm17QJyDQGtFLimKwEhp3izIodTrqA.jpg)
| 无法释放 | cursor: no-drop; |
cursor: text; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTGquCiLjk3I25--7dubWdG_5KcMeswUTmGQcsKizsqhEddxiDatHwGzsAxxRn_37k4.jpg)
| 文字/编辑 | The cursor indicates text 游标暗示当前所处位置为文字内容 |
cursor: move; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTF9RVHYVp6AaxxCrjeto4ZcT5VQyYbKS4_9_SB2nQGFx3llDDOolnp51LeolQooA4I.jpg)
| 可移动对象 | The cursor indicates something that should be moved 游标暗示一些东西应该被移动 |
cursor:vertical-text | | 可编辑的垂直文本的光标 | IE6.0用于标示可编辑的垂直文本的光标。通常是大写字母 I 旋转90度的形状。 |
cursor: n-resize; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTEwqysBd1QTpfGrjIa2SC_BFpW0N6cgzRSKI9eGvcpJKwCqySL8jSbWz4Wk6TtBt1w.jpg)
| 向上改变大小(North) | The cursor indicates that an edge of a box is to be moved up (north) 边缘可向上移动(北) |
cursor: s-resize; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTFfc-A7J4Io9IuMfAYI3FOmVI-uqP5X7zg9cilzxmfV8idWYlaXpLRLJx0ycLEGTAs.jpg)
| 向下改变大小(South) | The cursor indicates that an edge of a box is to be moved down (south) 边缘可向下方移动(南) |
cursor: e-resize; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTF7l-Or0uJnUVUh92d18dYfEfyf2lL_zObAT2obcviplE5YQx2648YW07axeZsfjkQ.jpg)
| 向右改变大小(East) | The cursor indicates that an edge of a box is to be moved right (east) box边缘可向右(东)边移动 |
cursor: w-resize; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTEujVFIXzTEaoG0_oBObd2TzjCaTXQBbVqU6l5NVEhQrKKhMIfUyJkdd_BZTid8RPs.jpg)
| 向左改变大小(West) | The cursor indicates that an edge of a box is to be moved left (west) 边缘可向左移动(西) |
cursor: ne-resize; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTGIQIBfvgC9P15xpoDHHHH5ztO6IvjANKD149a92XQLt2wLmIubv8mg--EJ4NQUwYI.jpg)
| 向上右改变大小(North East) | The cursor indicates that an edge of a box is to be moved up and right (north/east) 游标暗示box的边缘可向右上方移动(东北方向) |
cursor: nw-resize; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTFUgKTuadkibHgz4F1eXfK-5jeKdsa1-A2Fwrl584r-dGP2SDZNw8v7CuufUI_vYTc.jpg)
| 向上左改变大小(North West) | The cursor indicates that an edge of a box is to be moved up and left (north/west) 边缘可向左上方移动(西北) |
cursor: se-resize; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTHae03lmw5w5dPvjEPsxrCrBPvhC5-F0pvOcRARXHn5kwe_XrUSHU-6OAOOXtyp1Oo.jpg)
| 向下右改变大小(South East) | The cursor indicates that an edge of a box is to be moved down and right (south/east) 边缘可向右下方移动(东南) |
cursor: sw-resize; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTEDg5X-DzAoWGA20Z7E-tZoyKpiPoCMFMyXzn8TLzyHbG_PU2gilbXRz34fW2JYKls.jpg)
| 向下左改变大小(South West) | The cursor indicates that an edge of a box is to be moved down and left (south/west) 边缘可向左下方移动(西南) |
cursor:col-resize; | | 项目可被水平改变尺寸 | IE6.0有左右两个箭头,中间由竖线分隔开的光标。用于标示项目或标题栏可以被水平改变尺寸。 |
cursor:row-resize; | | 项目可被垂直改变尺寸 | IE6.0有上下两个箭头,中间由横线分隔开的光标。用于标示项目或标题栏可以被垂直改变尺寸。 |
cursor:not-allowed; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTFwuoD8byeHsSkzmP3nHXOhaHNATW2p0b7OuBmebPBoe6rkf-pSlHSodhLVsiFvVaU.jpg)
| 禁止 | cursor:not-allowed; |
cursor: progress; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTFpuJGKqJ0jvaDh8MFmiA5RchS--7lTkNzzek1JTC1jWVL--g0y9M5Zh9UL6IJtsKw.jpg)
| 处理中 | cursor: progress; |
cursor: default; | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTGllwGavSkucYeOG5W_xq0-MeNZt2j7L39_wKVpV73vUBlUYv6kJao_8fBunfEa2uE.jpg)
| 系统默认 | The default cursor (often an arrow) 默认的游标状态(通常为一个箭头) |
cursor: url(' # '); # = 光标文件地址 (注意文件格式必须为:.cur 或 .ani)。 | ![CSS cursor鼠标样式一览表 CSS cursor鼠标样式一览表](https://cdn.ancii.com/article/image/v1/Us/oO/ff/ffosOUFGfhDfTsPGWup--9-Gf9kUuACXBTRrh0fdkTH0cQ8iOVp5kyf9sS3u3agiR_t-G0tSL35TnWi5k042N9WnPFo7MYvp7s9sxInNGuk.jpg)
| 用户自定义(可用动画) | The url of a custom cursor to be used. 自定义游标的url位置 Note: Always define a generic cursor at the end of the list in case none of the url-defined cursors can be used 注意:在定义完自定义的游标之后在末尾加上一般性的游标,以防那些url所定义的游标不能使用 |