windows 上下文菜单的捕获窗口(Alt-Print Screen)

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/242609/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-09 05:37:19  来源:igfitidea点击:

Capture Window (Alt-Print Screen) of Context Menu

windowsscreenshotbug-trackingscreen-captureprintscreen

提问by moogs

As everyone knows, sometimes developers have to document stuff. Or capture some stuff for filing bug reports.

众所周知,有时开发人员必须记录一些东西。或者捕获一些用于提交错误报告的东西。

My question is in MS Windows.

我的问题是在 MS Windows 中。

I'm trying to capture the context menu (the popup menu that appears after right-clicking an item) of several areas of an application. Pressing Altto start the Alt+PrintScreenprocess closes the context menu.

我正在尝试捕获应用程序多个区域的上下文菜单(右键单击某个项目后出现的弹出菜单)。按Alt开始Alt+PrintScreen进程关闭上下文菜单。

(Only pressing PrintScreenhelps, but it's painful to remove the non-window areas everytime).

(只有按下才有PrintScreen帮助,但每次都删除非窗口区域很痛苦)。

BONUS: For capturing menus, Altalso closes the menu. However, if you use the Altkey to open the menu in the first place, it works:

奖励:对于捕获菜单,Alt也会关闭菜单。但是,如果您首先使用该Alt键打开菜单,它会起作用:

  1. Press Alt+F(for opening the "File" menu), don't release Alt
  2. Press PrintScreen
  3. Tada!
  1. Alt+ F(打开“文件”菜单),不要松开Alt
  2. PrintScreen
  3. 多田!

采纳答案by MrZebra

You can't get the menu on its own, but you can get it to capture the parent window + context menu through a similar trick to the one you discovered with the main menu:

您无法自行获取菜单,但您可以通过与您在主菜单中发现的技巧类似的技巧来获取它来捕获父窗口 + 上下文菜单:

  1. Press & hold Shift
  2. Press F10
  3. Press and hold Alt(you're still holding down Shift)
  4. Press PrintScreen
  5. Release Shift+ Alt
  1. 按住 Shift
  2. F10
  3. 按住Alt(你仍然按住Shift
  4. PrintScreen
  5. 发布Shift+Alt

At least you don't have to install any software!

至少你不用安装任何软件!

回答by Nate

Using Windows 7, I used Ctrland PrntScrat the same time.

使用Windows 7,我同时使用CtrlPrntScr

That captured the entire screen. I then pasted (Ctrl+ V) into an image editor, and cropped out everything except the context menu.

这捕获了整个屏幕。然后我将 ( Ctrl+V)粘贴到图像编辑器中,并裁剪掉上下文菜单之外的所有内容。

I do have the Windows High Contrast Acccessibility Modedisabled on my computer (Control Panel -> Ease of Access Center -> Make the computer easier to see -> uncheck "Turn on or off High Contrast ..."). I'm not sure if that was necessary or not.

我的计算机上确实禁用了 Windows高对比度辅助功能模式控制面板 -> 轻松访问中心 -> 使计算机更易于查看 -> 取消选中“打开或关闭高对比度...”)。我不确定这是否有必要。



Note:if your keyboard does not have PrntScras a primary key (it might show in small blue font), then obviously you'll have to adjust for that (e.g. you may need to press Altto get the PrntScrfunction, which means a total key sequence of Ctrl+ Alt+ PrntScron your keyboard).

注意:如果您的键盘没有PrntScr作为主键(它可能以蓝色小字体显示),那么显然您必须对此进行调整(例如,您可能需要按下Alt才能获得该PrntScr功能,这意味着总键序列的Ctrl+ Alt+PrntScr键盘上)。

回答by Bernd

Just press Print Screen. It will capture whole screen. Then open paint to a new window, and press Ctrl+Vto paste then crop.

只需按Print Screen。它将捕获整个屏幕。然后打开油漆到一个新窗口,然后按Ctrl+V粘贴然后裁剪。

回答by sdiggly

There's actually a slightly easier way for those users of the Snipping Tool.. I pulled this from the Microsoft site itself. It's from this site: http://windows.microsoft.com/en-us/windows/use-snipping-tool-capture-screen-shots#1TC=windows-7

对于 Snipping Tool 的那些用户来说,实际上有一个稍微简单的方法。我从 Microsoft 站点本身中提取了这个。它来自这个站点:http: //windows.microsoft.com/en-us/windows/use-snipping-tool-capture-screen-shots#1TC=windows-7

If you want to capture a snip of a menu, such as the Start menu, follow these steps:

如果要捕获菜单的片段,例如“开始”菜单,请执行以下步骤:

Open Snipping Tool by clicking the Start button Picture of the Start button. In the search box, type Snipping Tool, and then, in the list of results, click Snipping Tool.

单击“开始”按钮,打开“截图工具”。“开始”按钮的图片。在搜索框中,键入截图工具,然后在结果列表中单击截图工具。

After you open Snipping Tool, press Esc, and then open the menu that you want to capture.

打开截图工具后,按 Esc,然后打开要捕获的菜单。

Press Ctrl+PrtScn

按 Ctrl+PrtScn

Click the arrow next to the New button, select Free-form Snip, Rectangular Snip, Window Snip, or Full-screen Snip from the list, and then select the area of your screen that you want to capture.

单击“新建”按钮旁边的箭头,从列​​表中选择“自由格式截图”、“矩形截图”、“窗口截图”或“全屏截图”,然后选择要捕获的屏幕区域。

回答by whiz

Try SnagIT. Works like a warm knife in butter! Also see this: https://stackoverflow.com/questions/26183/screenshot-taking-tools

试试SnagIT。就像一把温暖的黄油刀!另请参阅:https: //stackoverflow.com/questions/26183/screenshot-taking-tools

回答by Dero

there is much easier way, simply

有更简单的方法,简单地

  1. use snipping tool but with delay option (let's say 3 seconds)
  2. click on "new"
  3. do whatever you want (right click drop down menu, etc.)
  4. save the output.
  1. 使用截图工具但带有延迟选项(假设为 3 秒)
  2. 点击“新建”
  3. 随心所欲(右键单击下拉菜单等)
  4. 保存输出。

:)

:)

回答by Alexandru Pupsa

Press Ctrl+ Alt+ Print Screen.

Ctrl+ Alt+ Print Screen

The Ctrlwon't do anything, but it will prevent Altfor closing the context menu.

Ctrl不会做任何事情,但它会防止Alt关闭的上下文菜单。

回答by Vinzz

You might give a try to FastStone Capturewhich is imho the best tool for this kind of bug filing/doc making stuff.

您可以尝试使用FastStone Capture,恕我直言,这是进行此类错误归档/文档制作的最佳工具。

With this app, just right click on the mouse so as to show the contextual menu, hit print screen, et voilà!

使用此应用程序,只需右键单击鼠标即可显示上下文菜单,点击打印屏幕,等等!

回答by Vinzz

You could use Screenshot Captor(free).

您可以使用Screenshot Captor(免费)。

You can do a Windows Object Capture to grab onlythe context menu (works with menu capturing as well), or just normal printscreen key to capture the whole screen.

您可以执行 Windows 对象捕获以抓取上下文菜单(也可以与菜单捕获一起使用),或者仅使用普通的打印屏幕键来捕获整个屏幕。

-mouser

-鼠标

[disclaimer -- i am the author of Screenshot Captor]

[免责声明——我是 Screenshot Captor 的作者]

回答by PhiLho

I tried with my favorite, free screen capture software: MWSnap. I activated a shortkey (Ctrl+ Shift+ Z) to window/menu capture function, and while it was in background, I called Firefox's context menu on this page and used the shortkey. MWSnap highlighted the menu and upon clicking, captured it flawlessly.

我尝试使用我最喜欢的免费屏幕捕获软件:MWSnap。我激活了一个快捷键(Ctrl+ Shift+ Z)到窗口/菜单捕获功能,当它在后台时,我在这个页面上调用了 Firefox 的上下文菜单并使用了快捷键。MWSnap 突出显示了菜单,点击后完美捕捉。

Probably works with other screen capture softwares. PrintScreen is so obsolete... :-P

可能适用于其他屏幕捕获软件。PrintScreen 太过时了... :-P

(Bonus: no Paint to open, save in any common format (PNG, Jpeg) you want, autosave & auto-number of captures if you want, etc.)

(奖励:无需打开油漆,以您想要的任何常用格式(PNG,Jpeg)保存,如果需要,自动保存和自动捕获数量等)