9

Is there a way to get textboxes, labels and other wpf controls in xna that supports margins, etc that flexes for window size?

Shawn Mclean
  • 56,733
  • 95
  • 279
  • 406

5 Answers5

8

You might give CeGui a shot.

If your game needs advanced GUI capabilities, CeGui# might just hit the nail on the head for you. Marketese aside, this is a seriously good GUI library with Buttons, ListBoxes, Scrollbars, ProgressBars, Sliders, ComboBoxes and more.

To access the Xna version you'll need to check out the latest copy from the project's SVN and load up CeGui-XNA.sln.

There are other options listed in this thread, but I have no idea how well any of the others work (and it probably isn't a comprehensive list anymore).

Ryan Versaw
  • 6,417
  • 3
  • 30
  • 31
  • 1
    Yea, looks like i'm going to have to go with a 3rd party library for now. I'm using neoforce, found here http://www.tomshane.cz/neoforce/default.aspx – Shawn Mclean Oct 14 '09 at 04:40
  • That's looking pretty nice - and actively developed! – Ryan Versaw Oct 14 '09 at 06:08
  • It looks like this project has been renamed to Nuclex.Userinterface. The link to CeGui redirects to http://nuclexframework.codeplex.com/wikipage?title=Nuclex.UserInterface – Daniel Plaisted Jan 13 '11 at 06:38
6

The official GUI systems FAQ thread in the XNA Forum: What GUI systems are there for the XNA framework?

CEGUI# is powerful, but it doesn't support the Xbox 360 (eg. its design doesn't include responding to game pad input) - a major overhaul would be required to refit it to be usable with something else than mouse and keyboard.

Cygon
  • 9,444
  • 8
  • 42
  • 50
2

Not exactly what you're looking for, but here is an example of getting winforms GUI elements mixed in with XNA 3d content:

http://creators.xna.com/en-US/sample/winforms_series1

Adam Kane
  • 3,996
  • 7
  • 44
  • 53
2

Check out SQUID: http://www.ionstar.org/

It's a really clean, fast, and engine independent UI system. I've worked with it extensively and really enjoy using it. The download includes sample code for XNA 3.1, Truevision3D, and SlimDX.

Dan
  • 91
  • 1
  • 3
1

It is possible to embed an XNA game in a WPF form (google: XNA in WPF) if you target only Windows system. You will then have access to all the controls available in XPF for your 2D GUI.

If you also target Xbox 360 or Zune; you must make your own GUI library :(

Jodi
  • 900
  • 7
  • 14