Jump to content
Frequently Asked Questions
  • Are you not able to open the client? Try following our getting started guide
  • Still not working? Try downloading and running JarFix
  • Help! My bot doesn't do anything! Enable fresh start in client settings and restart the client
  • How to purchase with PayPal/OSRS/Crypto gold? You can purchase vouchers from other users
  • DBUI - Custom GUI look & feel API


    Articron

    Recommended Posts

    • 7 months later...
    • 4 months later...
    Posted

    Great contribution, really loving the aesthetic the GUI offers. Thanks & will be crediting you on release


     

    cffee309d24ffa0933d2d67930c7509b.png

    • 8 months later...
    Posted
    2 hours ago, notafraid90 said:

    image.png.ae3ea2bb78e7fb34dff2ba12059ea3c5.png

     

    I'm getting two headers! What am I missing?

    You may want to declare the frame as undecorated.

    Posted
    1 minute ago, Hashtag said:

    You may want to declare the frame as undecorated.

    I did both in my Swing invokeLater and in the DreamFrame constuctor. I also made sure its before setting it visible. I don't understand.

    • 1 year later...
    Posted
    On 3/18/2021 at 9:21 PM, notafraid90 said:

    I did both in my Swing invokeLater and in the DreamFrame constuctor. I also made sure its before setting it visible. I don't understand.

    This can be solved by calling this line before you initialize your gui:

    JFrame.setDefaultLookAndFeelDecorated(false);

     

    On another note, I dislike the library because of 3 reasons:

    1. The close button in DreamHeader exits the client. You should make the following change:
      //closeBtn.addActionListener(l -> System.exit(0));
      closeBtn.addActionListener(l -> SwingUtilities.windowForComponent(this).dispose());
    2. The DreamBot logo is fetched from the internet for no reason at all. Because of this, the gui initialization must be wrapped in try-catch statement (ImageIO exception) and there is this redundant class VisualTools that resizes the image from the internet. Instead, the library should get the DreamBot icon from the client's JFrame as following:
      ((JFrame) SwingUtilities.windowForComponent(Instance.getCanvas())).getIconImage()
    3. This library is commonly used in SDN scripts and I cringe every time I see these "flaws" in new scripts to be released.

    Archived

    This topic is now archived and is closed to further replies.

    ×
    ×
    • Create New...

    Important Information

    We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.