diff --git a/src/gui/components/cc_frm.cpp b/src/gui/components/cc_frm.cpp index bfa2839ae..4a474bbb3 100644 --- a/src/gui/components/cc_frm.cpp +++ b/src/gui/components/cc_frm.cpp @@ -355,6 +355,9 @@ void CComponentsForm::paintCCItems() int right_item = cc_item->getRealXPos() + w_item; int w_diff = right_item - right_frm; int new_w = w_item - w_diff; + //avoid of width error due to odd values (1 line only) + right_item -= (new_w%2); + w_item -= (new_w%2); if (right_item > right_frm){ printf("[CComponentsForm] %s: [form: %d] [item-index %d] [type=%d] width is too large, definied width=%d, possible width=%d \n", __func__, cc_item_index, cc_item->getIndex(), cc_item->getItemType(), w_item, new_w); @@ -366,6 +369,9 @@ void CComponentsForm::paintCCItems() int bottom_item = cc_item->getRealYPos() + h_item; int h_diff = bottom_item - bottom_frm; int new_h = h_item - h_diff; + //avoid of height error due to odd values (1 line only) + bottom_item -= (new_h%2); + h_item -= (new_h%2); if (bottom_item > bottom_frm){ printf("[CComponentsForm] %s: [form: %d] [item-index %d] [type=%d] height is too large, definied height=%d, possible height=%d \n", __func__, cc_item_index, cc_item->getIndex(), cc_item->getItemType(), h_item, new_h);