diff options
author | NetaP495L <netap495l@163.com> | 2021-07-31 19:57:39 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-07-31 19:57:39 +0800 |
commit | 75258c7a0fa043c3e373f8a933332595e298a3f1 (patch) | |
tree | d0b6a120eda8ec3457e5331b88259cdd20a5994f /files/zh-cn/web/api/canvas_api | |
parent | 17dbc4b436381a778fd2661efe729e8f3ee4ac6c (diff) | |
download | translated-content-75258c7a0fa043c3e373f8a933332595e298a3f1.tar.gz translated-content-75258c7a0fa043c3e373f8a933332595e298a3f1.tar.bz2 translated-content-75258c7a0fa043c3e373f8a933332595e298a3f1.zip |
fix code style Web/API/Canvas_API/Tutorial/Pixel_manipulation_with_canvas, zh-CN (#1817)
Diffstat (limited to 'files/zh-cn/web/api/canvas_api')
-rw-r--r-- | files/zh-cn/web/api/canvas_api/tutorial/pixel_manipulation_with_canvas/index.html | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/files/zh-cn/web/api/canvas_api/tutorial/pixel_manipulation_with_canvas/index.html b/files/zh-cn/web/api/canvas_api/tutorial/pixel_manipulation_with_canvas/index.html index 268d375903..e18a67a753 100644 --- a/files/zh-cn/web/api/canvas_api/tutorial/pixel_manipulation_with_canvas/index.html +++ b/files/zh-cn/web/api/canvas_api/tutorial/pixel_manipulation_with_canvas/index.html @@ -70,7 +70,7 @@ translation_of: Web/API/Canvas_API/Tutorial/Pixel_manipulation_with_canvas <h3 id="A_color_picker" name="A_color_picker"><strong>颜色选择器</strong></h3> -<p>在这个例子里面,我们会使用<code style="font-style: normal;">getImageData()去展示鼠标光标下的颜色。为此,我们要当前鼠标的位置,记为layerX和layerY,然后我们去查询getImageData()给我们提供的在那个位置的像数数组里面的像素数据。最后我们使用数组数据去设置背景颜色和<div>的文字去展示颜色值。</code></p> +<p>在这个例子里面,我们会使用<code style="font-style: normal;">getImageData()</code>去展示鼠标光标下的颜色。为此,我们要当前鼠标的位置,记为layerX和layerY,然后我们去查询<code style="font-style: normal;">getImageData()</code>给我们提供的在那个位置的像数数组里面的像素数据。最后我们使用数组数据去设置背景颜色和<div>的文字去展示颜色值。</code></p> <div class="hidden"> <pre class="brush: html; notranslate"><canvas id="canvas" width="300" height="227" style="float:left"></canvas> |