I am looking forward to using a component library(perhaps richfaces or primefaces) with JSF for developing the frontend of a social application.
I need to know:
1.) how far is it possible to customize the look of each individual component independently besides choosing a single theme for all components. Is it possible to use CSS with these components.
2.) Can I use multiple component libraries (depending on what components I need) in a single project?
3.) Any suggestions on choosing a component library also welcomed!
EDIT
4.) Are there any visual editors for developing UI with these libraries? I currently use netbeans 6.9 IDE.
I know it's possible with RichFaces
Yes, it's possible. Most probably you have to customize at least one of them to get a consistent layout. For some libraries there exist already such themes, e.g. you find some themes for Primefaces with Richfaces look and feel.
We decided to use RichFaces which provides various well documented
components. Look at the examples of
your library candidates and decide
if they might fit your needs.
Richfaces:
http://livedemo.exadel.com/richfaces-demo/richfaces/modalPanel.js
Primefaces:
http://www.primefaces.org/showcase/ui/home.jsf
Apache MyFaces Trinidad:
http://myfaces.apache.org/trinidad/index.html
I love Primefaces as they have a probably the largest and some of the most feature rich components available. It takes a litle tweaking but you could use other component libraries with Primefaces as well.
Be prepared though for a lot of issues. There are a lot of bugs however if you are decently good with javascript and CSS and have above a beginners level understanding of JSF then you should have no problems working around them. Just be prepared to implement a couple of smelly hacks to meet some requirements.
Despite these problems I notice it becoming more and more stable with every release so it will only get better from here.
I use primefaces, and customizing each component is pretty easy and fun. They have samples in their user-guide on how to customize each component (css). Primefaces relies heavily on jQuery(I noticed by looking at the source generated), but also uses other javascript libraries like YUI. Sometimes it could be very Javascript intensive on the client, but so far, it does what is says it do very well.
I am not sure about the multiple components, never tried it, and per my own recommendations, I think primefaces rocks.
AS from netbeans 7.0, primefaces is included in Netbeans, so you don't have to worry about configurations anymore.
See that you got some answer already. I had more or less the same questions as you have. In the end I went for Richfaces, because the following points
Better integrated with the core JSF 2.0 libarary and has more or less the same monoculture.
No payload on bandwidth, when not using any Richfaces component, this will happens if you use Primefaces. Because the jquery and CSS will always load, whenever you using a component or not.
The documentations is bit more comprehensive. But the Primefaces forum is more active and you'll get a better feedback
The bandwidth was the key point for me, so I picked Richfaces. But I like the Primefaces library too, since the verity of components is greater.
Related
We have a java wicket 1.4 application not so large, but now we need to integrate bootstrap 4 to it. Consulting the apache wicket site, we see a integration come since wicket 6.0 version but it is not supported for older versions.
Having project time considerations, We have two alternatives: First, migrate from 1.4 to 1.5 and then to 6.0, this to support the "native" integration, or second, to include bootstrap in the html head instead of the html generated directly from wicket.
The first one is probably the best option but could imply a great effort. The second one, is not a clean solution but could be a temporal one.
Do you know which implications or potential issues could be arise both alternatives?
I guess you want to use https://github.com/l0rdn1kk0n/wicket-bootstrap because Wicket itself doesn't provide anything special for Bootstrap. The "problem" here is this library does not provide integration with Bootstrap 4 (https://github.com/l0rdn1kk0n/wicket-bootstrap/issues/540) because v4 is "almost ready" for about 3 years now.
I'd suggest you to use the second approach.
Updating to a newer version of Wicket would be good anyway! Ignoring the new features and the bug fixes there are several security fixes which might or might not affect your application.
Use the second approach - add the bootstrap.css to your html head and use bootstrap classes manually in your html. Just use standard Wicket. Some bootstrap components like Slider, Progress Bar, Datepicker and Modal we have implemented as components on our own.
This gives you full control and free's you from external libraries which are not updated in time, not compatible with other frameworks/versions and so on.
We are happy with this approach and avoid this way the problem you have.
I'm interested in using XUL as a standard way of defining my Java app (both Swing and web alike) UIs. To do this, I need two major components:
An open source GUI builder that allows me to drag n'drop UI elements, like Abeille forms or Matisse, etc., and export these UIs into a standards-compliant XUL file
A Java lib for reading that exported XUL file and building UI components out of it
I would have thought this would be easy to find, however there are a number of problems:
For one, I can't seem to find an "official" XSD Schema for XUL (even off of Mozilla's site), so it doesn't seem to be universally enforced/validated from a central schema, and as such, seems to have lots of conflicting variations across various XUL tools/products
Hence, gettting one tool that can export a XUL file, and a Java lib to read that XUL file without errors, seems to be difficult/impossible
All the XUL-based GUI builders I've found seem to be proprietary and expensive
The only Java libs that can read XUL files seem to be billed as "XUL toolkits" and include a web server, templating engine, etc. In other words, they are overkill for what I need, which is something that can read a XUL file and produce a container object full of UI widgets.
Anyone have any idea as to how I could marry these two ideas together and accomplish what I need? Thanks in advance!
I once explored that avenue with many toolkits. From my experience, it is not worth it, but why not give it another try?...
I needed the following :
CSS Integration, if possible, to skin the UI
Scripting using Rhino and/or other JVM scripting languages
XML markup support and basic Swing integration (Not really important)
I ended up customizing an existing library. I can't recall the exact name, but I think it was a fork of swingml to support inline scripting better. I improved the Rhino support and also hooked some Jython integration.
There were many other options, but nothing that was really astonishing.
I also tried to use Apache Commons Jelly (main library behind early Apache Maven versions). Commons Jelly has/had a Jelly Swing module.
At the end, I realized that it wasn't both convenient and time saving, in addition to overhead (Java reflection and dynamic method dispatching, proxies and interaction with JVM scripting languages -> scoping among other things, etc.).
I have developed some years ago and I am currently refreshing a Java sourceforge project based on XUL, and integrating scripting languages called javaXUL: https://sourceforge.net/projects/javaxul/
Check http://www.zkoss.org/product/zk
I have used zk in past it's a nice tool based on XUL. It has community edition as well as License version.
Please check if this will help. thanks
In my new project client has requested to use GWT/SmartGWT for developing presentation tier. (Note: Screens are not much complex)
I am aware about the MVP Pattern (never used) but I need to decide which flavor of the MVP pattern I should use which meets following criteria.
I should be able to integrate/use SmartGWT components seamlessly with the MVP framework.
It would be great if framework provides me flexibility to support UI to be displayed on Mobile or iPad sort of devices.
I have noticed before that when components of GWT and SmartGWT used together the behavior is inconsistent. Correct me here is it true yet?
Any guidance on this would be highly appreciated.
Thanks!!
Bhavesh
MVP is a pattern Google created for the base GWT widgets, which do not have support for data binding built in. Google has never said that MVP applies to SmartGWT widgets, where the widgets already have support for data binding, and we (Isomorphic) strongly advise against trying to use Google MVP with SmartGWT unless you have very specific, very unusual needs (more on this here:
SmartGWT GWT client server architecture)
When people try to apply MVP to SmartGWT, we see them re-creating functionality that already exists in SmartGWT, making things vastly more complicated than they need to be, and repeatedly looking for APIs and override points that aren't there because they are re-inventing things that are built into the framework. And this experience is not unique to SmartGWT - many of GWT's smartest users are complaining that MVP creates complexity and unneeded code even with the core GWT widgets.
So our advice is: start with the SmartGWT QuickStart Guide, and only look at MVP or other third-party architectural advice when you find a concrete, specific problem SmartGWT clearly doesn't address (still waiting to hear about this :).
It does not play very well together, in fact most widget libraries fail in this area.
It's not impossible, but not there yet.
Yes, SmartGWT is a component library, you'll be using their widgets just like those that come with GWT.
It might work, but don't expect it'd be just like on the desktop (I had some issues with scrolling, but that might have been my mistake, we don't use smartGWT any more)
Regarding the interplay, yes, it's correct, they don't mix well, but in some cases it might work. It's better not to mix. At least that was my experience with SmartGWT 2.2.
Can anyone suggest a good UI framework that can be used in a Java EE web application?
I will be doing a project that requires to generate a web UI on the fly. Regular JSP page coding makes it hard to do. There is a framework called Vaadin. It looks good to do a dynamic UI implementation. However, I don't know if it stable for production use. If there is any other good suggestion, please let me know.
I'd suggest Wicket. It's been in production use for years, it's very stable, it's very programmer-friendly, and it can easily handle dynamic UIs.
(But I have to agree that the Vaadin demos look hot)
I would say vaadin would be easier over wicket as the default UI elements look really good.
Wicket, you will need to create your own css to make things look good (other than default html UI)
vaadin 6.5.0 was released a couple of days ago and has been there for a long time but recently made open source probably around 2-3 years ago at most if i remember right.
I love both Vaadin and Wicket and my opinion is that they are the best 2 frameworks out there.
However, for this case, I would choose vaadin cause it is easier to get better looking UI elements
I used to work with JSF - Richfaces but had no idea of how to start it and I quit before I learned it.
Is there any easy way to start? What do I need to add. Like splitting projects into 4 or so and what server to use, etc.
You can also find many RichFaces resources on my blog: http://mkblog.exadel.com/tag/richfaces-howto/, including this project template: http://mkblog.exadel.com/2010/04/the-easiest-way-to-start-with-richfaces/
Here is hello world and Practical Richfaces
But I suggest you to use Primefaces. I think primefaces is the best among jsf components because of its ajax and ui facilities
although I don't have a tutorial to suggest to you, I would recommend when experimenting with Richfaces components, to look them up in the live demo, where code snippets and examples are shown. For each component you can find additional information in the "Developer Guide" link in the upper left corner.
As far as Eclipse is concerned and since you are using Richfaces, I would definitely use install the JBoss Tools plugin, which has handy features, such as auto-complete, visual editing etc.