guy 5e097d8630 Gestita meglio la chiamata di programmi Windows in cascata
git-svn-id: svn://10.65.10.50/trunk@110 c028cbd2-c16b-5b4b-a496-9718f37d4682
1994-08-31 12:20:38 +00:00

81 lines
1.4 KiB
C++
Executable File

#ifndef __FORM_H
#define __FORM_H
#ifndef __PRINTER_H
#include <printer.h>
#endif
#ifndef __RELATION_H
class TRelation;
class TCursor;
#endif
#ifndef __SCANNER_H
#include <scanner.h>
#endif
class TForm;
class TForm_item;
class TPrint_section : public TArray
{
TString16 _name;
int _heigth;
TForm* _form;
TArray _item;
protected:
virtual void print_on(ostream& out) const;
TForm_item* parse_item(TScanner& scanner);
public:
TPrintrow& row(int num);
TForm* form() const { return _form; }
TForm_item* item(int n) const { return (TForm_item*)_item.objptr(n); }
int items() const { return _item.items(); }
bool update();
bool parse(TScanner& scanner);
bool edit(int mode);
TPrint_section(const char* name = "", TForm* form = NULL);
void init(const char* name, TForm* form);
};
class TForm : public TObject
{
TFilename _name;
TRelation* _relation;
TCursor* _cursor;
TPrint_section _head;
TPrint_section _body;
TPrint_section _foot;
protected:
virtual void print_on(ostream& out) const;
bool parse_use(TScanner&);
bool parse_join(TScanner&);
bool set_header();
bool set_footer();
public:
bool print(long from = 0L, long to = -1L);
TRelation* relation() const { return _relation; }
TCursor* cursor() const { return _cursor; }
bool edit(int mode, int section = 1);
TForm(const char* form);
~TForm();
};
#endif