#include <stdio.h>

extern class Shared *shared;	   // accessible everywhere
extern UPix bricks_pix, term_pix, ubit_pix, eyes_pix, mail_pix, manual_pix;

class Shared {
public:
  UTextbox  shtext;
  UBgcolor bgcolor;
  class UTimer *timer;
  UCheckbox *check1, *check2;
  UVbox  mainPage;
  UMenu colorMenu;
  class UDialog *openDial, *saveDial;

  class Postit *transparent_postit;

  class OptButton: public UButton {
  public: 
    UButton redBtn, yellowBtn, blueBtn, whiteBtn;
  } optbutton;

  Shared(UAppli*);
};

class Postit : public UVbox {
  UBackground *backgd;
  UColor  *txtcolor;
  ULabel  *handle;
  UButton *ctrlbtn, *ctrlbtn2;  
  UPos    *pos;
  u_pos   last_x, last_y;

  void press(UEvent&);
  void drag(UEvent&);
  void paintGraphics(UEvent&);
  void setBackgd(UEvent&, int); 

public:
  Postit(u_pos x, u_pos y, UArgs a = UArgs::none);
};





