Question

Two-part question.

1) I have absolutely nothing against ClientBundle; it's great (minification, obfuscation, etc, of the developer's input CSS), but I'm wondering, is there is another way to style a CellTable? The obfuscated (generated) class names are used to style the table. Is there a way (hack, or not) to turn this use of generated CSS off, and override the class names in a more direct way (say through a reference in the index.html file to a CSS file with the ".cellTable*" class names), without using ClientBundle?

2) Going with the ClientBundle route, I see that the CSS file that overrides/replaces the default GWT CSS classes has to be referenced in code like this :

public interface TableResources extends CellTable.Resources {

    interface TableStyle extends CellTable.Style {
    }

    @Override
    @Source({ CellTable.Style.DEFAULT_CSS, "/CellTableStyle.css" })
    TableStyle cellTableStyle();
}

...where "/CellTableStyle.css" is under the same package as TableResources. Is there a way to reference a CSS file that is not in the same package as the interface, and say is in a different source directory than the base src dir of the project?

Was it helpful?

Solution

"Is there a way to reference a CSS file that is not in the same package as the interface, and say is in a different source directory than the base src dir of the project?"

Just reference it in your .html file

<link rel="stylesheet" type="text/css" href="relative/path/to/your/CSS">
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top