html style mouse cursor

. 1 <span style = "Cursor: pointer"> hand </ span> 
 2 <span style = "Cursor: Crosshair"> cross </ span> 
 . 3 <span style = "Cursor: text"> text cursor </ span> 
 . 4 <span style = "cursor: wait "> wait </ span> 
 . 5 <span style = "Cursor: default"> default </ span> 
 . 6 <span style = "Cursor: Help"> question mark </ span> 
 . 7 <span style = "cursor: e-resize "> left arrow </ span> 
 . 8 <span style = "Cursor: S-a resize"> down arrow </ span> 
 . 9 <span style = "Cursor: Auto" automatically give> system effects </ span>
 10 <span style = "Cursor:url (aaa.cur '); "> custom icon </ span>

This thing is amazing, since we use the definition of dynamic graphic effect is very good, oh! You can make your page style extra show!

Cursor cursor using
the type attribute specifies a cursor to be displayed cursor (shape), the attribute defines the shape of the mouse pointer when the cursor is placed within the boundaries of an element used (although CSS2.1 does not define the boundary which is determined by the scope of this).

Default value: auto; Inheritance: yes; Version: CSS2;

JavaScript syntax: object.style.cursor = "crosshair";

All major browsers support cursor attributes. Note: Opera 9.3 and Safari 3 does not support the url value, any version of Internet Explorer (including IE8) support the property value "inherit".

cursor: url () custom cursor URL. Plurality may be provided, comma separated, a first load failed is displayed behind.

css: {cursor: url (image path), - moz-zoom-out ;} // FF compatible
css: {cursor: url (image path), auto;} // IE, FF, chrome browsers can
foregoing url () is defined from addresses mouse style image, the latter parameter is standard cursor css styles (IEs below may not be needed)

Note: Always define a generic cursor, such as auto at the end of this list, in case the URL definition of the cursor can not be displayed properly when the cursor is not available.

Format icon to points depending on the browser: IE supports cur, ani, ico three formats, FF supports bmp, gif, jpg, cur, ico these types of formats, so the general use or cur ico image formats.

If ani format, can be jpg, gif, bmp FF in place of the following (cursor: url (xxx.ani), url (xxx.gif), auto)

The best picture size is 32 * 32, anyway, in each browser the following analytical sample sizes.

IE using cursor url () Mouse flashing problem occurs: When setting cursor: when URL () adds a title or container element alt, this phenomenon occurs. The title tag can be removed.

Guess you like

Origin www.cnblogs.com/GGbondLearn/p/12239886.html