当前位置: 首页 > 图文教程 > 网络编程 > Javascript > JavaScript入门教程(5) js Screen屏幕对象

Javascript
javascript删除Table中的一行的脚本代码
非常不错的[JS]Cookie精通之路
日历控件在FF2.0,ie6下测试可用
JavaScript 给汉字排序实例代码
js查找父节点的简单方法
js禁用和激活input表单的方法
js兼容标准的表格变色效果
js文字滚动停顿效果代码
js打字机效果代码
复制本贴标题和地址的js代码
js兼容IE6,IE7菜单高亮显示效果代码
Class Of Marquee Scroll通用不间断滚动JS封装类
不错的JavaScript面向对象的简单入门介绍
Javascript&DHTML基础知识
Javascript & DHTML DOM基础和基本API
Javascript & DHTML上传文件控件
javascript indexOf函数使用说明
用JS剩余字数计算的代码
javascript 火狐(firefox)不显示本地图片问题解决
Javascript入门学习第一篇 js基础

Javascript 中的 JavaScript入门教程(5) js Screen屏幕对象


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-09-12   浏览: 247 ::
收藏到网摘: n/a

这是基本JavaScript的屏幕对象

screen 屏幕对象 反映了当前用户的屏幕设置。
width 返回屏幕的宽度(像素数)。
height 返回屏幕的高度。
availWidth 返回屏幕的可用宽度(除去了一些不自动隐藏的类似任务栏的东西所占用的宽度)。
availHeight 返回屏幕的可用高度。
colorDepth 返回当前颜色设置所用的位数 - 1:黑白;8:256色;16:增强色;24/32:真彩色
下面是英文的Navigator浏览器的屏幕对象:
availHeight:minus permanent or semipermanent user interface features displayed by the operating system:such as the Taskbar on Windows.
availWidth:Specifies the width of the screen, in pixels, minus permanent or semipermanent user interface:features displayed by the operating system, such as the Taskbar on Windows.
colorDepth:The bit depth of the color palette, if one is in use; otherwise, the value is derived from screen.pixelDepth.
height:Display screen height.
pixelDepth:Display screen color resolution (bits per pixel).
width:Display screen width.