improve filebox appearance on Linux
This commit is contained in:
@@ -3862,7 +3862,7 @@ namespace nana
|
||||
{
|
||||
nana::rectangle imgt(item.img_show_size);
|
||||
img_r = imgt;
|
||||
img_r.x = content_pos + coord.x + (16 - static_cast<int>(item.img_show_size.width)) / 2; // center in 16 - geom scheme?
|
||||
img_r.x = content_pos + coord.x + 2 + (16 - static_cast<int>(item.img_show_size.width)) / 2; // center in 16 - geom scheme?
|
||||
img_r.y = coord.y + (static_cast<int>(essence_->item_height()) - static_cast<int>(item.img_show_size.height)) / 2; // center
|
||||
}
|
||||
content_pos += 18; // image width, geom scheme?
|
||||
|
||||
@@ -1522,11 +1522,12 @@ namespace nana
|
||||
{
|
||||
const nana::paint::image * img = nullptr;
|
||||
auto & item_attr = compset->item_attribute();
|
||||
if (item_attr.mouse_pointed)
|
||||
img = &(item_attr.icon_hover);
|
||||
else if (item_attr.expended)
|
||||
img = &(item_attr.icon_expanded);
|
||||
|
||||
if (item_attr.expended)
|
||||
img = &(item_attr.icon_expanded);
|
||||
else if (item_attr.mouse_pointed)
|
||||
img = &(item_attr.icon_hover);
|
||||
|
||||
if((nullptr == img) || img->empty())
|
||||
img = &(item_attr.icon_normal);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user