int width; // the width of the client and its border
int bwidth; // width to make borders
int cbwidth; // width of the inner client border
- int butsize=0; // width and height of the titlebar buttons
+ int fontheight = _style->labelFont()->height(); // height of the font
+ int butsize = fontheight - 2; // width and height of the titlebar buttons
const int bevel = _style->bevelWidth();
if (_decorations & Client::Decor_Border) {
_innersize.top += _titlebar.height() + bwidth;
// set the label size
- _label.setGeometry(0, bevel, width, _style->labelFont()->height());
+ _label.setGeometry(0, bevel, width, fontheight);
// set the buttons sizes
- butsize = _label.height() - 2;
if (_decorations & Client::Decor_Iconify)
_button_iconify.setGeometry(0, bevel + 1, butsize, butsize);
if (_decorations & Client::Decor_Maximize)
const int sep = bevel + 1;
otk::ustring layout;
- if (!python_get_string("titlebar_layout", &layout))
+ if (!python_get_string("TITLEBAR_LAYOUT", &layout))
layout = "ILMC";
// this code ensures that the string only has one of each possible
void Frame::adjustPosition()
{
int x, y;
+ x = _client->area().x();
+ y = _client->area().y();
clientGravity(x, y);
move(x, y);
}
void Frame::clientGravity(int &x, int &y)
{
- x = _client->area().x();
- y = _client->area().y();
-
// horizontal
switch (_client->gravity()) {
default:
void Frame::frameGravity(int &x, int &y)
{
- x = rect().x();
- y = rect().y();
-
// horizontal
switch (_client->gravity()) {
default: