class studio::AboutProgress : public synfig::ProgressCallback
{
About &about;
-
+
public:
AboutProgress(About &about):about(about) { }
-
+
virtual bool task(const std::string &task)
{
if(about.tasklabel)
#else
imagepath=IMAGE_DIR;
#endif
+ char* synfig_root=getenv("SYNFIG_ROOT");
+ if(synfig_root) {
+ imagepath=synfig_root;
+ imagepath+=ETL_DIRECTORY_SEPERATOR;
+
+ imagepath+="share/pixmaps";
+ }
imagepath+=ETL_DIRECTORY_SEPERATOR;
-
-
+
+
// Create the Logo
Gtk::Image *Logo = manage(new class Gtk::Image());
Logo->set(imagepath+"about_dialog."IMAGE_EXT);
Logo->set_size_request(image_w,image_h);
Logo->set_alignment(0.5,0.5);
Logo->set_padding(0,0);
-
+
// Create the Copyright Label
Gtk::Label *CopyrightLabel = manage(new class Gtk::Label(SYNFIG_COPYRIGHT));
CopyrightLabel->set_size_request(image_w,24);
VersionLabel->set_padding(0,0);
VersionLabel->set_justify(Gtk::JUSTIFY_CENTER);
VersionLabel->set_line_wrap(false);
-
+
// Set the version label to contain the correct information
string ver;
ver+="Version "VERSION" ("__DATE__" "__TIME__")\n";
Gtk::Image *image2 = manage(new class Gtk::Image(Gtk::StockID("gtk-close"), Gtk::IconSize(4)));
image2->set_alignment(0.5,0.5);
image2->set_padding(0,0);
-
+
// Create the close button, and attach the image to it
CloseButton = manage(new class Gtk::Button());
CloseButton->set_size_request(24,24);
tasklabel = manage(new class Gtk::Label());
tasklabel->set_size_request(image_w,24);
tasklabel->set_use_underline(false);
-
+
// Create the Gtk::Fixed container and put all of the widgets into it
Gtk::Fixed *fixed1 = manage(new class Gtk::Fixed());
fixed1->put(*Logo, 0, 0);
if(x==true)
CloseButton->show();
else
- CloseButton->hide();
+ CloseButton->hide();
}
synfig::ProgressCallback *