Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2002-03

Conversion from c

2 messages · 2 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Unknown author

I would like to use a library written in C
paragui

but it use classes like this :

class DECLSPEC PG_Button : public PG_Widget {
public:
/**
Constructor for the PG_Button class
@param parent pointer to the parent widget or NULL @param id id of the button (can be used in callbacks) @param r screen position of the button
@param text button label
@param style themestyle of the button
*/
PG_Button(PG_Widget* parent, int id, const PG_Rect& r, const char* text = NULL, const char* style="Button");

	virtual ~PG_Button();
	void LoadThemeStyle(const char* widgettype);

is it possible to use it?
Lionel Drevon
Adeli http://www.adeli.fr
618 Av. Gal de Gaulle Tel 04 78 66 11 85
69760 Limonest Fax 04 78 66 04 33

Thomas Schatzl
to Unknown author

Subject: [fpc-pascal]Conversion from c

I would like to use a library written in C paragui

It's C++, not C.

but it use classes like this :

That's why ^^ (and the paragui homepage says C++ as well)

Show quoted text 16 lines
class DECLSPEC PG_Button : public PG_Widget { public: /** Constructor for the PG_Button class @param parent pointer to the parent widget or NULL @param id id of the button (can be used in callbacks) @param r screen position of the button @param text button label @param style themestyle of the button */ PG_Button(PG_Widget* parent, int id, const PG_Rect& r, const char* text = NULL, const char* style="Button"); virtual ~PG_Button(); void LoadThemeStyle(const char* widgettype); is it possible to use it?

No, afaik C++ classes can't be used in FPC (yet?).

Regards,
Thomas