Functions

/home/koen/project/wt/public-git/wt/examples/hangman/hangman.C File Reference

#include <Wt/WApplication>
#include "HangmanGame.h"

Go to the source code of this file.

Functions

WApplicationcreateApplication (const WEnvironment &env)
int main (int argc, char **argv)

Function Documentation

WApplication* createApplication ( const WEnvironment env )

Definition at line 9 of file hangman.C.

{
  WApplication *app = new WApplication(env);
  app->setTitle(L"Hangman");
  new HangmanGame(app->root());  

  /*
   * The application style sheet (only for the highscore widget)
   */
  WCssDecorationStyle cellStyle;
  WBorder cellBorder;
  cellBorder.setStyle(WBorder::Solid);
  cellBorder.setWidth(WBorder::Explicit, 1);
  cellBorder.setColor(WColor(Wt::lightGray));
  cellStyle.setBorder(cellBorder);

  app->styleSheet().addRule(".highscores * TD", cellStyle);

  cellStyle.font().setVariant(WFont::SmallCaps);

  app->styleSheet().addRule(".highscoresheader", cellStyle);

  cellStyle.font().setVariant(WFont::NormalVariant);
  cellStyle.font().setStyle(WFont::Italic);
  cellStyle.font().setWeight(WFont::Bold);

  app->styleSheet().addRule(".highscoresself", cellStyle);

  return app;
}
int main ( int  argc,
char **  argv 
)

Definition at line 40 of file hangman.C.

{
   return WRun(argc, argv, &createApplication);
}

Generated on Fri Jul 8 2011 for the C++ Web Toolkit (Wt) by doxygen 1.7.2