uicomponents

How to display buffered image in JSF without writing image on disk?

ε祈祈猫儿з 提交于 2019-12-01 07:51:40
问题 I have a buffered image and I need to display it in a JSF page. Is there any UI component available which can display a buffered image directly? I am using JSF 2.2. 回答1: If you only have the buffered image, you could use the Omnifaces library to which allows you to render images by passing a byte[] to the component <o:graphicImage value="#{bean.image}" dataURI="true" /> If you have the buffered image you could convert to byte array like so: ByteArrayOutputStream baos = new

Find component by type in JSF

末鹿安然 提交于 2019-11-30 09:25:41
My question is related to this one Get all hidden input fields in JSF dynamically but it's not the same as I want to work with JSF and not plain HTML, and assuming that I have the following in my .xhtml file: <h:inputHidden id="name1" value="SomeValue1"/> <h:inputHidden id="name2" value="SomeValue2"/> I developed a small code where I tried to get all the h:inputHidden tags dynamically and print their values to the console, but the problem is that I can't figure out a way how to make everythning dynamic. In my code I should know the form id if I want to Iterate over the uicomponents, how can I

What is the Best UI Component Set for WPF? [closed]

坚强是说给别人听的谎言 提交于 2019-11-29 01:22:17
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 4 years ago . Looking for a general purpose WPF toolset. Currently looking at Telerik and Infragistics. Are there better options out there? Of those two, which is better? 回答1: I'm still of the opinion that you don't need to get a third-party control library early in a new WPF project in the same way we all feel when doing

How to add progress bar control to Matlab gui?

北城以北 提交于 2019-11-28 21:21:44
Is there a ready made progress bar uicontrol that can be added to Matlab gui, either uicontrol or ActiveX component? [edit] I know about the waitbar function, I meant a component that can be implemented into the designed GUI and not just pop out of the window. Something like battery status in status bar. Waitbar and its variants display a popup window with a status bar. In most applications this is ok and very simple to use. If you want to integrate a progress-bar within an existing GUI window, you have several choices: implement the internal waitbar code - this is really just an axes that

Embed XNA in WinForms

杀马特。学长 韩版系。学妹 提交于 2019-11-28 10:50:01
Is it possible to embed an XNA game in a C# WinForm or a C++ Window. If yes then How. I want to use normal UI controls & have a windowed interface of the game for more interactive & dynamic simulations. Andrew Russell The official samples: XNA WinForms Series 1: Graphics Device XNA WinForms Series 2: Content Loading I've had success doing this using the method described here: XNA 3.0 and Winforms, the easy way The blog post was written for XNA 3.0, but I had no problems using the same method with XNA 4.0. It's very simple compared to the official Microsoft sample, but as this method is not

How to add progress bar control to Matlab gui?

房东的猫 提交于 2019-11-27 20:55:12
问题 Is there a ready made progress bar uicontrol that can be added to Matlab gui, either uicontrol or ActiveX component? [edit] I know about the waitbar function, I meant a component that can be implemented into the designed GUI and not just pop out of the window. Something like battery status in status bar. 回答1: Waitbar and its variants display a popup window with a status bar. In most applications this is ok and very simple to use. If you want to integrate a progress-bar within an existing GUI

Embed XNA in WinForms

对着背影说爱祢 提交于 2019-11-27 05:54:46
问题 Is it possible to embed an XNA game in a C# WinForm or a C++ Window. If yes then How. I want to use normal UI controls & have a windowed interface of the game for more interactive & dynamic simulations. 回答1: The official samples: XNA WinForms Series 1: Graphics Device XNA WinForms Series 2: Content Loading 回答2: I've had success doing this using the method described here: XNA 3.0 and Winforms, the easy way The blog post was written for XNA 3.0, but I had no problems using the same method with

How to pass custom component parameters in java and xml

烈酒焚心 提交于 2019-11-27 02:52:32
When creating a custom component in android it is often asked how to create and pass through the attrs property to the constructor. It is often suggested that when creating a component in java that you simply use the default constructor, i.e. new MyComponent(context); rather than attempting to create an attrs object to pass through to the overloaded constructor often seen in xml based custom components. I've tried to create an attrs object and it doesn't seem either easy or at all possible (without an exceedingly complicated process), and by all accounts isn't really required. My question is

What exactly is #{component} in EL?

瘦欲@ 提交于 2019-11-26 17:19:24
问题 According to https://code.google.com/p/primefaces/issues/detail?id=4720, The ComponentUtils.resolveWidgetVar(String expression, UIComponent component) function is available in Primefaces since 2013. It can be used in EL by the "#{p:widgetVarFromContext(searchExpression, component)}" function. This is useful in case of several components have the same id in different NamingContainer , but are still present in the same view. In this case, the #{p:widgetVar(searchExpression)} function only

Find component by ID in JSF

雨燕双飞 提交于 2019-11-26 12:24:29
问题 I want to find some UIComponent from managed bean by the id that I have provided. I have written the following code: private UIComponent getUIComponent(String id) { return FacesContext.getCurrentInstance().getViewRoot().findComponent(id) ; } I have defined a p:inputTextarea as: <p:inputTextarea id=\"activityDescription\" value=\"#{adminController.activityDTO.activityDescription}\" required=\"true\" maxlength=\"120\" autoResize=\"true\" counter=\"counter\" counterTemplate=\"{0} characters