i am using eclipse helios 3.6 and i am developing JSF pages (Dynamic Web Project With JSF Capabilities) and sometimes i need to add style to a component in the xhtml page
<h:commandLink style="margin-righ:10px">
(not a style class) and i want to add CSS autocomplete to eclipse how to do so ? please advise, thanks.
In Eclipse click Windows Drop-Down > Click Preferences > Navigate to Java > Editor > Content Assist In order to Make the Auto suggestion/completion to work you have to set trigger that invoke the Auto Completion.
Eclipse Web Developer Tools Includes the HTML, CSS, and JSON Editors, and JavaScript Development Tools from the Eclipse Web Tools Platform project, aimed at supporting client-side web development and node.
You could add the CSS files with the _ URL, a _ url tag, or a URL key and tag s file) to your HTML document file using the link > tag. link in the * tag, following an element of the URL title you specify below, within * head and after the * nd within the head > section, and after the title > element of your HTML file.
Go:
Window -> Preferences -> Web -> CSS files -> Editor -> Content assist.
And make sure the checkboxes are checked
EDIT: Ok... Then try with these:
Window -> Preferences -> General -> Content Types -> Text -> JSP -> Add (*.css)
OR
Window -> Preferences -> General -> Content Types -> Text -> Java Source File -> Add (*.css)
Try with these and see if it solves your problem
EDIT 2: Plus try this:
Window -> Preferences -> General -> Editors -> File Association -> Add (*.css)
EDIT 3:
Window -> Preferences -> General -> Editors -> File Association
make sure it looks like this, it works for me with the autocompletion:
You need to install a WTP extension plugin (WTP Web resources). See my answer here https://stackoverflow.com/a/43549935/2459094.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With