问题描述
[这个问题与 有关这个问题]
设置:我有这个自制的可编辑标签"组件,它看起来像一个标签,但是当您单击它时,它会变成一个可编辑字段,允许您对其进行编辑.您可以按 Esc 取消,或按 Shift-Enter 来确定您的编辑 - 或单击可编辑字段下方的相应按钮.
Setting: I have this home-crafted "editable label" component which looks like a label, but when you click it, it turns into an editable field, allowing you to edit it. You can hit Esc to cancel, or Shift-Enter to OK your edits - or click the respective buttons beneath the editable field.
挑战:当点击编辑时,我希望整个 UI 都被涂白",除了编辑标签的区域,向用户清楚地表明他应该在哪里重点.
The Challenge: When hitting edit, I want the entire UI to be "whited out", except for the edit-label's area, to clearly denote to the user where it is expected that he should focus.
推荐答案
替代方案,这可以使用 JXLayer 项目来实现.看看他们的一些演示,在选择物品时,他们会在其中模糊GUI.您必须实现自己的 JXLayer 视图才能使 GUI 变白.
Alternative, this could be achieved using the JXLayer project. Take a look at some of their demos where they blur out the GUI when an item is selected. You would have to implement your own JXLayer view in order to white out your GUI.
项目网址:https://jxlayer.dev.java.net/
演示位于首页的入门"项下.
Demos are under the "getting started" item on the front page.
这篇关于“白化"除了一个组件之外的整个摆动 GUI的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!