Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7437155
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T10:21:18+00:00 2026-05-29T10:21:18+00:00

I just started to port twitter’s bootstrap to GWT (see the github project here

  • 0

I just started to port twitter’s bootstrap to GWT (see the github project here and a very ugly demo here), but, I was having a log of issues with bootstrap styles vs Gwt styles.

Bootstrap put a border-top in tr/td elements, and GWT components basically use tables everywhere. In the demo you can see that bug in the left VerticalPanel.

So, I was looking for a way to make GWT components ignore bootstrap styles, and I have no idea how to do this.

Is there a simple way to make it work right?

Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T10:21:19+00:00Added an answer on May 29, 2026 at 10:21 am

    It’s possible, but somewhat complex to do something with a Linker in GWT. The high-level idea would be:

    1. Put all your GWT components in a <div id=”gwt”>…</div>
    2. Add a linker to the GWT Module file that will process CSS files.
    3. In the linker, transform the GWT CSS (e.g., standard.css) to insert a #gwt before each selector rule.

    The first part is easy, just add an id to your root element.

    The second part is also easy, simply add code that looks like this to your Module.gwt.xml file:

    <define-linker name="cssLinker" class="com.you.bootstrap.linker.CssRenamingLinker" />
    <add-linker name="cssLinker"/>
    

    The hard part is implementing the Linker. It’s possible to do parse it by hand, but you might find it easier to use something like SAC.

    Using the Linker, you can transform your CSS by inserting a #gwt before each selector. Using SAC, you might do that by overriding all the DocumentHandler methods to simply emit each of their arguments to an OutputStream. In DocumentHandler.startSelector() you would first emit “#gwt ” before each selector.

    [Edit]
    This assumes that GWT’s standard.css defines styles that override the bootstrap styles. If not, you might have to ‘enhance’ the GWT CSS with defaults. There’s a list of W3C recommended defaults here.

    The benefit is that this is future-resistant – if GWT styles change or if bootstrap styles change, this should be robust.

    Hope that helps,

    Adam

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

HI all, I'm just getting started with developing for Android. I'm looking to port
I just started thinking about creating/customizing a web crawler today, and know very little
I just started to play around with MongoDB (C#) and tried to port a
I've just started playing with ssh on Mac. I want to setup ssh port
I started testing Mail API; All examples I could see require to know port
Just started getting a bunch of errors on our C# .Net app that seemed
Just started to get my feet wet with C# and .NET, liking it so
Just started with JQuery and I've managed to pass a parameter using POST, firebug
Just started my first MVC 2.0 .net application. And I set up some default
Just started working with .NET and MVC(1). I'm having a problem wherein in my

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.