diff options
author | Peter Bengtsson <mail@peterbe.com> | 2020-12-08 14:40:17 -0500 |
---|---|---|
committer | Peter Bengtsson <mail@peterbe.com> | 2020-12-08 14:40:17 -0500 |
commit | 33058f2b292b3a581333bdfb21b8f671898c5060 (patch) | |
tree | 51c3e392513ec574331b2d3f85c394445ea803c6 /files/ja/web/api/mouseevent/altkey | |
parent | 8b66d724f7caf0157093fb09cfec8fbd0c6ad50a (diff) | |
download | translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.tar.gz translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.tar.bz2 translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.zip |
initial commit
Diffstat (limited to 'files/ja/web/api/mouseevent/altkey')
-rw-r--r-- | files/ja/web/api/mouseevent/altkey/index.html | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/files/ja/web/api/mouseevent/altkey/index.html b/files/ja/web/api/mouseevent/altkey/index.html new file mode 100644 index 0000000000..9316f58644 --- /dev/null +++ b/files/ja/web/api/mouseevent/altkey/index.html @@ -0,0 +1,44 @@ +--- +title: event.altKey +slug: Web/API/MouseEvent/altKey +tags: + - DOM + - Gecko + - Gecko DOM Reference +translation_of: Web/API/MouseEvent/altKey +--- +<p>{{ ApiRef() }}</p> +<h3 id="Summary" name="Summary">Summary</h3> +<p>イベントが発生したときALTキーが押されていたかどうかを示します。</p> +<h3 id="Syntax" name="Syntax">Syntax</h3> +<pre class="eval"><i>bool</i> = event.altKey +</pre> +<p><code>bool</code> は <code>true</code> か <code>false</code> であり、イベントが発生したときに ALT キーが押されていたかどうかを示しています。</p> +<h3 id="Example" name="Example">Example</h3> +<pre><html> +<head> +<title>altKey example</title> + +<script type="text/javascript"> + +function showChar(e){ + alert( + "Key Pressed: " + String.fromCharCode(e.charCode) + "\n" + + "charCode: " + e.charCode + "\n" + + "ALT key pressed: " + e.altKey + "\n" + ); +} + +</script> +</head> + +<body onkeypress="showChar(event);"> +<p> +Press any character key, +with or without holding down the ALT key.<br /> +You can also use the SHIFT key together with the ALT key. +</p> +</body> +</html> +</pre> +<p>{{ languages( { "en": "en/DOM/event.altKey", "pl": "pl/DOM/event.altKey" } ) }}</p> |