From owner-freebsd-libh Tue Jan 16 6:23: 6 2001 Delivered-To: freebsd-libh@freebsd.org Received: from usw4.freebsd.org (usw4.freebsd.org [209.180.6.228]) by hub.freebsd.org (Postfix) with ESMTP id C4BAD37B402 for ; Tue, 16 Jan 2001 06:22:49 -0800 (PST) Received: (from alex@localhost) by usw4.freebsd.org (8.11.1/8.9.3) id f0GEMnD77245 for libh@FreeBSD.org; Tue, 16 Jan 2001 08:22:49 -0600 (CST) (envelope-from alex) Message-Id: <200101161422.f0GEMnD77245@usw4.freebsd.org> From: Alexander Langer Date: Tue, 16 Jan 2001 08:22:49 -0600 (CST) To: libh@FreeBSD.org Subject: cvs commit: libh/lib/hui HuiQt.cc HuiQt.hh Sender: owner-freebsd-libh@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG alex 2001/01/16 08:22:49 CST Modified files: lib/hui HuiQt.cc HuiQt.hh Log: HuiQt::Widget::move(): Use a nicer and shorter way to calculate the new position. HuiQt::TitledWidget::move(): I forgot to add the code for calculating the offset. Add it, so that finally widgets with a label as title and a ContainerWidget as parent are moved to the correct position. In general: Add a new meaning of the values given to the "resize" function of a widget. This doesn't change the old behaviour: If a Widget is a child of a container widget whose arrangement is either vertical or horizontal, it can force a given width or height by setting this value explicitely and setting the other one to -1. This is recognized in the resize() function and the "FixedSize" is saved in a new value of the class. The parent who arranges the childs then checks, if a child has a fixed size set. If so, this widget is set to this size. The remainding space (if any) of the parent is then shared between the remainding widgets (if any). I used a new algorythm here, so that now every pixel of the parent is used. Before it might have happened the following: A container/groupwidget has 5 childs but it's size is only 5*x + 4 pixels. That meant that 4 pixels were left blank. Now these pixels are shared. Revision Changes Path 1.19 +328 -124 libh/lib/hui/HuiQt.cc 1.14 +28 -9 libh/lib/hui/HuiQt.hh To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-libh" in the body of the message