问题标签 [screens]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
1 回答
81 浏览

android - Android如何实现两屏,两个Activity,并且它们是独立的

我是Android新手,现在需要写一个android app:两屏也显示两个activity,大屏播广告,小屏可以操作,相互独立。当人操作小屏幕,广告仍然会播放。我在android 4.4 API 20中找到了presentation类,用它可以实现两屏显示不同的内容,我也参考了google的demo,但是由于presentation依赖于具体的activity,当小屏操作时,intent到了另外一个活动,之前打广告的介绍就消失了。于是我想出了一个方法:应用只有一个activity,小屏使用了很多fragment,但是因为下面的screen操作很复杂,用fragment会比较麻烦,

0 投票
4 回答
4207 浏览

android - 如何在 Android Wear 上检测圆形屏幕 - 设备上未调用 onApplyWindowInsets

我在 Android Wear 项目中实现了 onApplyWindowInsets 回调。在该方法中,它调用 isRound() 来确定代码是在圆形还是矩形 Wear 智能手表上运行。这个回调是从圆形磨损模拟器中调用的。(虽然 isRound() 返回 false,这是错误的。)但问题是我的 Samsung Gear Live 从未调用过 onApplyWindowInsets 回调。因此,如果从 onApplyWindowInsets 膨胀视图,则视图不会膨胀。有没有人让 onApplyWindowInsets 在真实设备上触发?似乎不能保证。如果是这样,那么如何根据屏幕类型膨胀不同的视图?

0 投票
1 回答
374 浏览

android - android SDK,一次性欢迎布局

因此,在我的应用程序中,我有一个欢迎布局或帮助布局,向您展示应用程序的工作原理以及它可以做什么,我希望它只在安装应用程序时显示一次,然后不再显示。如果这是可能的,那么最简单的方法是什么?

0 投票
1 回答
1024 浏览

python - 使用 Qt Designer 创建多屏应用程序

我正在使用 Qt Designer 创建 UI 设计,然后将其转换为 python 代码。由于我对 Qt 很陌生,所以我想问一下:有没有办法可以实现多屏应用程序?即单击下一个按钮并在同一窗口中获取一组新的选项/小部件等。

老实说,我是使用 Kivy 进行开发的,尽管如此流畅(尤其是多屏幕),但它依赖于 PyGame,这被证明是一个巨大的可移植性头痛,所以我不得不切换到其他东西,PyQt 是下一个可行的选择(或者看起来如此)。

0 投票
0 回答
197 浏览

c# - Getting the numbers of monitors as present in Screen Resolution window

I need to find a way to get the correct ID's of the connected screens that will be equal to the numbers present in the Windows 7 or 8 Screen Resolution window.

I tried to use WMI query and calling Win32 API functions and still i cant get the correct numbers. The DeviceName (like '\.\DISPLAY4') has nothing to do with screen number 4 as shown in the Screen Resolution window.

The same problem (without a solution) has been posted in 2010 in this url: http://social.msdn.microsoft.com/Forums/windowsdesktop/en-US/668e3cf9-4e00-4b40-a6f8-c7d2fc1afd39/how-can-i-retrieve-monitor-information?forum=windowsgeneraldevelopmentissues

Microsoft's answer was that: "There is not a supported way to figour out the IDs that you referred to programmatically. It was never a design goal to provide a way for applications to label monitors with the same IDs that the screen resolution control panel uses.".

Maybe someone has an idea how it still could be possible?

0 投票
1 回答
1084 浏览

windows-8 - 从 Windows 8 注册表确定屏幕是否处于活动状态

我正在查看 HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\DISPLAY 中的监视器列表

在 Windows 7 中,每个屏幕节点下都有一个名为“Control”的子项,用于指示屏幕是否处于活动状态。在 Windows 8 中没有这样的子项。

如何从 Windows 8 注册表中确定监视器是否处于活动状态?

0 投票
1 回答
449 浏览

java - 更改屏幕时的 Libgdx 冻结

我找不到解决方案,我现在正在寻找几个小时......当我更换屏幕时,一切都冻结了。我不知道出了什么问题。一切都应该没问题。是因为记忆丢失还是循环在某处停止?

我的代码:

0 投票
0 回答
2428 浏览

windows - EnumDisplayDevices vs EnumDisplayMonitors

I have noticed that EnumDisplayDevices and EnumDisplayMonitors report different information on which monitor is attached to which port.

For example, i have 4 monitors attached to my graphics card. 3 of them are 1920x1080 and one of them is 1280x768.

The information i get from EnumDisplayMonitors is:

and the one from EnumDisplayDevices is:

Also i noticed that the order in EnumDisplayDevices is sometimes shuffled, so it could also be:

Anyways, which one is the correct one?

I am looking for this because i want to read the EDID data from the correct monitor.

0 投票
1 回答
7896 浏览

python - Kivy - 屏幕管理器 - 访问其他类中的属性

使用 Kivy 屏幕管理器,我创建了两个屏幕。在屏幕 1 中,我想更改屏幕 2 中的标签。我在我的代码中突出显示有问题的区域:

我的test.ky:

和我的screen.py

任何帮助是极大的赞赏!谢谢,尼科

0 投票
2 回答
46 浏览

android - 不同屏幕密度的 UI

我不了解旨在支持多种屏幕密度的资源配置限定符的好处,例如:

  • 对于 mdpi,您放置一个 100x100 像素的图标

  • 对于 hdpi,您放置一个 150x150 像素的图标

  • 对于 xhdpi,您放置一个 200x200 像素的图标

然后,您在尺寸为 100 x 100 dip的 imageView 中显示此图标,该图标已在不同尺寸和密度的多个屏幕上保持其尺寸。

为什么我们不直接使用上面资源中的 xhdpi 版本的图标作为基线资源,以便它在更高密度的屏幕上显示得很好,更流畅,同时 android 会重新调整它以适应更低密度的屏幕无论如何,xhdpi 版本的图标就足够了吗?

我希望我的解释清楚,谢谢