Ste*_*tew 59 windows windows-7 display multiple-monitors energy-saving
我希望能够在不需要时在我的两台显示器之一上“让显示器进入睡眠状态”,这样它就不会分散我的注意力或使用不必要的电源。
理想情况下,显示器将处于睡眠状态,但操作系统将保持双显示器模式,因此我仍然可以在睡眠显示器的显示空间中打开各种窗口,这意味着我不必在单显示器之间切换 -和双显示器模式。
也就是说,我还会考虑一种解决方案,它可以轻松地在单显示器和双显示器模式之间切换,而无需导航多个系统菜单。
小智 50
按Windows+ P- 系统会提示您从单个、扩展等中选择显示模式,因此可用于禁用辅助显示器。
我看到你想保持打开的窗户;这仍然使它们保持打开状态,但如果您启用单监视器模式,它确实会将它们全部显示在一个显示器上。但是,至少这种方法可以让您在不使用时关闭第二个发光的干扰。
这篇文章有点旧,但我遇到了类似的问题。我可以远程打开我的电脑/媒体播放器/灯,但我的 27" 电脑显示器在房间里发出分散注意力的光芒。为了最大限度地提高我的懒惰,我创建了一个简单的 Java 应用程序来使显示器变黑(我可以使用其他远程启动它工具)。
下面是我在 Windows 7 上测试过的 java 代码。它需要一个参数 0 到 max display-1。例如:java -jar Dimmer.jar 1将使我的第二台显示器变黑,没有参数将假定显示为 0
import java.awt.BorderLayout;
import java.awt.Color;
import java.awt.GraphicsDevice;
import java.awt.GraphicsEnvironment;
import java.awt.Rectangle;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.BorderFactory;
import javax.swing.JButton;
import javax.swing.JWindow;
import javax.swing.UIManager;
public class Dimmer extends JWindow
{
private static final long serialVersionUID = 3493635987367217622L;
private final int _screen;
public Dimmer ()
{
this(0);
}
public Dimmer (int screen)
{
super();
_screen = screen;
{
final JButton button = new JButton("click to exit");
button.setForeground(Color.gray);
button.setOpaque(false);
button.setContentAreaFilled(false);
button.setBorder(BorderFactory.createEmptyBorder());
button.addActionListener(new ActionListener()
{
@Override
public void actionPerformed(ActionEvent arg0)
{
System.exit(0);
}
});
add(button, BorderLayout.CENTER);
}
setAlwaysOnTop(true);
}
public void begin()
{
GraphicsDevice gda[] = GraphicsEnvironment.getLocalGraphicsEnvironment().getScreenDevices();
GraphicsDevice gd = gda[_screen];
getContentPane().setBackground(Color.black);
for (GraphicsDevice gdTmp : gda)
{
System.out.print( (gd == gdTmp) ? "->" : " ");
System.out.println(
"Screen(" + gdTmp.getDefaultConfiguration().getDevice().getIDstring() +")"
+" "+ gdTmp.getDefaultConfiguration().getBounds() );
}
Rectangle bounds = gd.getDefaultConfiguration().getBounds();
setLocation(bounds.getLocation());
setSize(bounds.getSize());
validate();
setVisible(true);
}
/**
* @param args
* @throws Exception
*/
public static void main(String[] args) throws Exception
{
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
Dimmer dimmer = new Dimmer(args.length == 1 ? Integer.valueOf(args[0]) : 0);
dimmer.begin();
}
}
Run Code Online (Sandbox Code Playgroud)
小智 7
另一种选择是 Nirsoft Multi Monitor 工具:http ://www.nirsoft.net/utils/multi_monitor_tool.html
您可以创建两个批处理文件 - 一个用于禁用显示 X,另一个用于启用。例如:
MultiMonitorTool.exe /disable 5
和
MultiMonitorTool.exe /enable 5
要查找显示编号,请打开 MultiMonitorTool.exe,右键单击显示,然后访问属性。
| 归档时间: |
|
| 查看次数: |
128851 次 |
| 最近记录: |