예제 #1
0
void
JXColHeaderWidget::ApertureResized
	(
	const JCoordinate dw,
	const JCoordinate dh
	)
{
	JXEditTable::ApertureResized(dw,dh);
	SetRowHeight(1, GetApertureHeight());
}
예제 #2
0
JXWidgetSet*
JXHorizPartition::CreateCompartment
	(
	const JIndex		index,
	const JCoordinate	position,
	const JCoordinate	size
	)
{
	JXWidgetSet* compartment =
		new JXWidgetSet(this, kFixedLeft, kVElastic,
						position,0, size, GetApertureHeight());
	assert( compartment != NULL );
	return compartment;
}
예제 #3
0
JXColHeaderWidget::JXColHeaderWidget
	(
	JXTable*			table,
	JXScrollbarSet*		scrollbarSet,
	JXContainer*		enclosure,
	const HSizingOption	hSizing,
	const VSizingOption	vSizing,
	const JCoordinate	x,
	const JCoordinate	y,
	const JCoordinate	w,
	const JCoordinate	h
	)
	:
	JXEditTable(h,1, NULL, enclosure, hSizing,vSizing, x,y, w,h)
{
	assert( table != NULL && scrollbarSet != NULL );

	itsTable = table;
	itsTable->SetColHeader(this);
	ListenTo(itsTable);

	itsHScrollbar = scrollbarSet->GetHScrollbar();
	ListenTo(itsHScrollbar);

	itsTitles = NULL;

	itsAllowColResizingFlag = kJFalse;
	itsMinColWidth          = 1;

	itsDragType = kInvalidDrag;

	itsDragLineCursor    = JXGetDragVertLineCursor(GetDisplay());
	itsDragAllLineCursor = JXGetDragAllVertLineCursor(GetDisplay());

	SetDrawOrder(kDrawByRow);
	SetRowBorderInfo(0, (GetColormap())->GetBlackColor());

	// override JXEditTable

	WantInput(kJFalse);
	SetBackColor((GetColormap())->GetDefaultBackColor());

	AppendRows(1, GetApertureHeight());
	AdjustToTable();
}
예제 #4
0
void
JXHorizPartition::SetCompartmentSizes()
{
	const JCoordinate h = GetApertureHeight();

	const JSize compartmentCount = GetCompartmentCount();
	JCoordinate x = 0;
	for (JIndex i=1; i<=compartmentCount; i++)
		{
		const JCoordinate w = GetCompartmentSize(i);
		assert( w >= JPartition::GetMinCompartmentSize(i) );

		JXContainer* compartment = GetCompartment(i);
		compartment->Place(x,0);
		compartment->SetSize(w,h);
		x += w + kDragRegionSize;
		}
}
void
GMFilterMBoxTable::SetFilter
	(
	GMFilter* filter
	)
{
	itsFilter	= filter;
	if (filter == NULL)
		{
		RemoveAllRows();
		}
	else if (GetRowCount() == 0)
		{
		AppendRow(GetApertureHeight());
		}
	AdjustButtons();
	TableRefresh();
}
예제 #6
0
JCoordinate
JXVertPartition::GetTotalSize()
	const
{
	return GetApertureHeight();
}