projects
/
synfig.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Tidying.
[synfig.git]
/
synfig-studio
/
trunk
/
src
/
gtkmm
/
dockmanager.cpp
diff --git
a/synfig-studio/trunk/src/gtkmm/dockmanager.cpp
b/synfig-studio/trunk/src/gtkmm/dockmanager.cpp
index
cc13a96
..
b483ae8
100644
(file)
--- a/
synfig-studio/trunk/src/gtkmm/dockmanager.cpp
+++ b/
synfig-studio/trunk/src/gtkmm/dockmanager.cpp
@@
-6,6
+6,7
@@
**
** \legal
** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
**
** \legal
** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
+** Copyright (c) 2007 Chris Moore
**
** This package is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License as
**
** This package is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License as
@@
-132,7
+133,8
@@
public:
if(key=="contents_size")
{
try {
if(key=="contents_size")
{
try {
-
+ int width, height;
+ Gtk::IconSize::lookup(Gtk::IconSize(4),width,height);
vector<int> data;
String::size_type n=0;
String value_(value);
vector<int> data;
String::size_type n=0;
String value_(value);
@@
-142,11
+144,17
@@
public:
if(!strscanf(value_,"%d",&size))
break;
size=size*screen_h/SCALE_FACTOR;
if(!strscanf(value_,"%d",&size))
break;
size=size*screen_h/SCALE_FACTOR;
+
+ // prevent errors like this, by allowing space for at least the dockable's icon:
+ // ** CRITICAL **: clearlooks_style_draw_box_gap: assertion `height >= -1' failed
+ if (size < height + 9) size = height + 9;
+
data.push_back(size);
n=value_.find(" ");
if(n==String::npos)
break;
data.push_back(size);
n=value_.find(" ");
if(n==String::npos)
break;
+ n++;
}
dock_dialog.set_dock_book_sizes(data);
}
}
dock_dialog.set_dock_book_sizes(data);
}
@@
-228,7
+236,7
@@
DockManager::~DockManager()
while(!dockable_list_.empty())
{
Dockable* dockable(dockable_list_.back());
while(!dockable_list_.empty())
{
Dockable* dockable(dockable_list_.back());
- synfig::info("DockManager::~DockManager(): Deleting dockable \"%s\"",dockable->get_name().c_str());
+
//
synfig::info("DockManager::~DockManager(): Deleting dockable \"%s\"",dockable->get_name().c_str());
dockable_list_.pop_back();
delete dockable;
}
dockable_list_.pop_back();
delete dockable;
}
@@
-238,7
+246,7
@@
void
DockManager::register_dockable(Dockable& x)
{
dockable_list_.push_back(&x);
DockManager::register_dockable(Dockable& x)
{
dockable_list_.push_back(&x);
- synfig::info("DockManager::register_dockable(): Registered dockable \"%s\"",dockable_list_.back()->get_name().c_str());
+
//
synfig::info("DockManager::register_dockable(): Registered dockable \"%s\"",dockable_list_.back()->get_name().c_str());
signal_dockable_registered()(&x);
}
signal_dockable_registered()(&x);
}