//===============================================================================
// Xe UI toolkit
//
// XeLayout
//  Private header file
//
// AUTHOR:  Gabor Nagy
// DATE:    2026-May-28 22:32:25
//
// Copyright (C) 1996-2026 by Gabor Nagy. All rights reserved.
//===============================================================================
#ifndef _XeLayoutP_h
#define _XeLayoutP_h

#include <Xe/ManagerP.h>
#include <Xe/Layout.h>

#if defined (__cplusplus) && (!(defined (__CPLUSLIBS)))
extern "C" {
#endif


//================================
// Class definition
//================================
// Class part
//================================
typedef struct _XeLayoutClassPart
{
	EPointer  Extension;
} XeLayoutClassPart;


//================================
// Class record
//================================
typedef struct _XeLayoutClassRec
{
	XeCompositeClassCore;
	XeConstraintClassPart  Constraint;
	XeManagerClassPart     Manager;
	XeLayoutClassPart      Layout_class;
} XeLayoutClassRec;

extern XeLayoutClassRec  _XeLayoutWidget_class;




//================================
// Instance definition
//================================
// Instance part
//================================
typedef struct
{
// Resources
//
	XeCoord2        Spacing, MarginSize;
	uint16_t        ShadowType;

	XePreferredSizeFunc  PreferredSizeFunc;  // Custom function to lay out XeManager's children and compute XeManager's preferred size
	XeLayoutFunc         LayoutFunc;         // Custom function to lay out XeManager children with a given XeManager size
} XeLayoutPart;


//================================
// Instance record
//================================
typedef struct _XeLayoutRec
{
	XeCompositeWidgetCore;

	XeBasePart      Base;
	XeManagerPart   Manager;
	XeLayoutPart    Layout;
} XeLayoutRec;


#if defined (__cplusplus) && (!(defined (__CPLUSLIBS)))
}	// Close scope of 'extern "C"' declaration
#endif

#endif  // _XeLayoutP_h
