* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
+ * License along with this library. If not, see <http://www.gnu.org/licenses/>.
*/
/*
#include "gtkorientable.h"
#include "gtkwindow.h"
#include "gtktypebuiltins.h"
+#include "gtkorientableprivate.h"
#include "gtkprivate.h"
#include "gtkintl.h"
#include "a11y/gtkpanedaccessible.h"
priv->child1 = NULL;
priv->child2 = NULL;
priv->handle = NULL;
- priv->cursor_type = GDK_CROSS;
priv->handle_pos.width = 5;
priv->handle_pos.height = 5;
{
case PROP_ORIENTATION:
priv->orientation = g_value_get_enum (value);
+ _gtk_orientable_set_style_classes (GTK_ORIENTABLE (paned));
if (priv->orientation == GTK_ORIENTATION_HORIZONTAL)
priv->cursor_type = GDK_SB_H_DOUBLE_ARROW;
if (priv->child1 && gtk_widget_get_visible (priv->child1))
{
get_preferred_size_for_size (priv->child1, orientation, size, &child_min, &child_nat);
- *minimum = child_min;
+ if (priv->child1_shrink && priv->orientation == orientation)
+ *minimum = 0;
+ else
+ *minimum = child_min;
*natural = child_nat;
}
if (priv->orientation == orientation)
{
- *minimum += child_min;
+ if (!priv->child2_shrink)
+ *minimum += child_min;
*natural += child_nat;
}
else