深入淺出HTML5編程

出版時(shí)間:2012-4  出版社:東南大學(xué)  作者:(美)弗里曼//羅布森  頁(yè)數(shù):573  字?jǐn)?shù):853000  
Tag標(biāo)簽:無(wú)  

內(nèi)容概要

你想要?jiǎng)?chuàng)建動(dòng)態(tài)的、交互的、富數(shù)據(jù)的、保持連接的網(wǎng)頁(yè)。等等,網(wǎng)頁(yè)?為什么不直接使用HMTL5來(lái)創(chuàng)建成熟的web應(yīng)用?還有,為什么不使用那些現(xiàn)代技術(shù)來(lái)實(shí)現(xiàn),它們?cè)缭谥С忠苿?dòng)設(shè)備的時(shí)候就已經(jīng)支持你的桌面瀏覽器了?而且,你當(dāng)然會(huì)希望使用所有最新的HTML5技術(shù),比如地理定位、視頻、二維制圖、網(wǎng)絡(luò)存儲(chǔ)、工作線程等等,對(duì)不對(duì)?
這本由Eric Freeman、Elisabeth
Robson著的《深入淺出HTML5編程(影印版)》就是你的特快車票,它可以帶你學(xué)習(xí)如何使用今天的標(biāo)準(zhǔn)同時(shí)也會(huì)是明日的最佳實(shí)踐來(lái)搭建Web應(yīng)用。同時(shí),你會(huì)在《深入淺出HTML5編程(影印版)》中了解HTML5的新API的基本知識(shí),甚至你還會(huì)弄明白這些API是如何與你的網(wǎng)頁(yè)進(jìn)行交互,JaVaScript如何為它們提供動(dòng)力,以及你如何使用它們來(lái)搭建能夠打動(dòng)你的老板并且吸引你的朋友的Web應(yīng)用。

作者簡(jiǎn)介

作者:(美國(guó))弗里曼(Eric Friiman) (美國(guó))羅布森(Elisabdth Robson)

書籍目錄

Intro
Getting to know HTML5: Welcome to Webville
IntroducingJavaScript and the DOM: A Little Code
Events, Handle and All That Jazz: A Little Interactiviy
JavaScript Functio and Objects: Serious JavaScript
Making Your HTML Location Aware: Geolocation
Talking to The Web: Extroverted Apps
Bringing Out Your Inner Artist: Canvas
Not Your Father's TV: Video... With Special Guest Star "Canvas"
Storing Things Locally: Web Storage
PuttingJavaScript to Work: Web Worke
Appendix: Top Ten Topics (We Didn't Cover)
Index

章節(jié)摘錄

版權(quán)頁(yè):   插圖:   Canvas is an element you place in your page to create a drawing space. The canvas has no default style or content until you provide it (so you won't see it on the page until you draw something in it or add a border with CSS). You can have more than one canvas on your page.Of course,you'll need to give each one a unique id to access each using JavaScript. To specify the size of the canvas element,use the width and height attributes on the element. Everything you put in canvas is drawn using JavaScript. To draw on the canvas,you first need to create a context.Currently,a 2D context is your only option,although other context types may exist in the future. A context is needed to draw in the canvas because it provides a specific kind of interface (e.g.,2D versus 3D).You'll be able to choose from more than one kind ofinterface to draw on a canvas. You access the canvas by using context properties and methods. To draw a rectangle in the canvas,use the context.fillRect method.This creates a rectangle filled with color. To create a rectangle outline,use strokeRect instead of tlIIRect. Use flIIStyle and strokeStyle to change the default fill and stroke color,which is black. You can specify colors using the same format as you use with CSS (e.g.,"black","#000000 ,"rgb(0,0,0)".Remember to put quotes around the value of the fillStyle. There is no fiIICircle method.To draw a circle in canvas,you need to draw an arc. To create arbitrary shapes or arcs,you first need to create a path. A path is a invisible line or shape you create that defines a line or area on the canvas.You can't see the path until you stroke or fill it. To create a triangle,create a path using beginPath,then use moveTo and lineTo to draw the path.Use closePath to join two points on the path. To draw a circle,create an arc that is 360 degrees.Your start angle is 0,and your end angle is 360 degrees. Angles are specified in canvas using radians,not degrees,so you need to convert from degrees to radians to specify your start and end angles. 360 degrees=2Pi radians. To draw text in canvas,use the fillText method. When you draw text in canvas,you need to specify the position,style,and other properties using context properties. When you set a context property,it applies to all the drawing that follows until you change the property again.For example,changing the fillStyle will affect the color of shapes and text you draw after setting the fillStyle. Add an image to your canvas with the drawlmage method. To add an image,you first need to create an image object and make sure it's completely loaded. Drawing on canvas is like doing "bitmap" drawing in graphics programs.

編輯推薦

《深入淺出HTML5編程(影印版)(英文)》編輯推薦:我們認(rèn)為你的時(shí)間如此寶貴以至于不應(yīng)該花費(fèi)在為新概念傷腦筋上面。這本由Eric Freeman、Elisabeth Robson著,運(yùn)用最新的認(rèn)知科學(xué)和學(xué)習(xí)理論打造多感官的學(xué)習(xí)體驗(yàn),運(yùn)用適合大腦工作方式的直觀的格式編排,而不是令人昏昏欲睡的密密麻麻的文字。

圖書封面

圖書標(biāo)簽Tags

無(wú)

評(píng)論、評(píng)分、閱讀與下載


    深入淺出HTML5編程 PDF格式下載


用戶評(píng)論 (總計(jì)5條)

 
 

  •   好書。。英語(yǔ)版就是好
  •   好Q的書哦~??!嘿嘿 希望不會(huì)很難
  •   多看點(diǎn)書,充實(shí)自己
  •   買了這個(gè)和js的,這本書的紙張明顯不如另一本。。。
  •   這個(gè)系列一直不錯(cuò),只是紙張?jiān)絹?lái)越差勁了
 

250萬(wàn)本中文圖書簡(jiǎn)介、評(píng)論、評(píng)分,PDF格式免費(fèi)下載。 第一圖書網(wǎng) 手機(jī)版

京ICP備13047387號(hào)-7