WindowsのSnipping Tool*で、蛍光ペンツールを使って直線を引く方法を教えてください。
Windowsのスニッピングツールには、Shiftを押しながら直線を引かせる方法がありません。Windows Ink Workspace」は、スニッピングとその部分の描画をサポートするもうひとつのツールです。このツールには、直線を引くのに役立つ仮想ルーラーがあります。
Windows Ink ワークスペースを有効にするには
タスクバー上の任意の場所を右クリックして、コンテキストメニューから Show Windows Ink Workspace」ボタンをクリックします。右端の通知領域に、ペンで "S "の字を書いているアイコンが表示されます。 の形をしたペンのアイコンが、通知領域の右端に表示されます。
ワークスペースを起動するには、通知領域に表示されるペン型のWindows Ink Workspaceアイコンをクリックまたはタップします。
画面のスケッチ」をタップします。これは、リストの3番目のブロックになります。自動的にディスプレイのスクリーンショットが撮影され、スケッチのために読み込まれます。
![Windows Ink ワークスペースでの画面スケッチ]]2.
画面右上のペンバーに移動します。
ルーラーのアイコンを選択します。これは、斜めの定規のように見えます。
マウスをルーラーの上に置き、マウスのスクロールホイールを使ってルーラーを回転させ、位置を決めます。
サンプルスケッチ。 ![サンプルスケッチ]]3.
ご参考になれば幸いです。
Note: スクリーンスケッチは、Windows 10 Anniversary Updateで利用できる新機能です。
ユーザーの3DWizardさんが素敵なAutoHotKeyスクリプトを公開されていますが、これを少し修正してこの問題を解決しました。Snipping Toolウィンドウ内でlt;kbd>Shiftを押したままにすると、マウスが水平方向にしか動かなくなります。
SendMode Input ; Recommended for new scripts due to its superior speed and reliability
SetTitleMatchMode 2 ; Allows for partial matches in window titles
; Commands specific to when Snipping Tool is open
#IfWinActive, Snipping Tool
$*Shift::
Send {Shift Down}
CoordMode, Mouse, Screen
MouseGetPos, SetX, SetY
; clip the cursor to a rectangle that consists just of a line in x-direction
ClipCursor(true, -1000000, SetY, 1000000, SetY+1)
KeyWait Shift
return
$*Shift Up::
Send {Shift Up}
ClipCursor(false, 0, 0, 0, 0) ; unclip the cursor
return
ClipCursor(Confine=True, x1=0 , y1=0, x2=1, y2=1)
{
VarSetCapacity(R, 16, 0), NumPut(x1, &R+0), NumPut(y1, &R+4), NumPut(x2, &R+8), NumPut(y2, &R+12)
Return Confine ? DllCall("ClipCursor", UInt, &R) : DllCall("ClipCursor")
}
#IfWinActive
The Answer by @HaveSpacesuit は、Windows 10では動作しませんでした。
Shiftを離してもカーソルが離されませんでした。
直すには、後ろから3行目を次のように変更します。
Return Confine ? DllCall( "ClipCursor", UInt,&R ) : DllCall( "ClipCursor", UInt, 0 )
全体、動作するコードです。
SendMode Input ; Recommended for new scripts due to its superior speed and reliability
SetTitleMatchMode 2 ; Allows for partial matches in window titles
CoordMode, Mouse, Screen
; Commands specific to when Snipping Tool is open
#IfWinActive, Snipping Tool
$*Shift::
Send {Shift Down}
MouseGetPos, SetX, SetY
ClipCursor( true, -10000, SetY, 10000, SetY+1 ) ;clip the cursor to a rectangle that consists just of a line in x-direction
KeyWait Shift
return
$*Shift Up::
Send {Shift Up}
ClipCursor( false, 0, 0, 0, 0 ) ; unclip the cursor
return
ClipCursor( Confine=True, x1=0 , y1=0, x2=1, y2=1 ) {
VarSetCapacity(R,16,0), NumPut(x1,&R+0),NumPut(y1,&R+4),NumPut(x2,&R+8),NumPut(y2,&R+12)
Return Confine ? DllCall( "ClipCursor", UInt,&R ) : DllCall( "ClipCursor", UInt, 0 )
}
#IfWinActive