Newt

 view release on metacpan or  search on metacpan

Newt.xs  view on Meta::CPAN

	 char *	text

void
newtBell()

void
newtGetScreenSize()
	PREINIT:
		int cols;
		int rows;
	PPCODE:
		newtGetScreenSize( &cols, &rows );
		XPUSHs(sv_2mortal(newSViv(cols)));
		XPUSHs(sv_2mortal(newSViv(rows)));

void
newtReflowText(width, flexDown, flexUp, text)
	int	width
	int	flexDown
	int	flexUp
	char *	text
	PREINIT:
		char *result;
		int actualWidth;
		int actualHeight;
	PPCODE:
		result = newtReflowText(text, width, flexDown, flexUp, &actualWidth, &actualHeight);
		XPUSHs(sv_2mortal(newSVpv(result, PL_na)));
		XPUSHs(sv_2mortal(newSViv(actualWidth)));
		XPUSHs(sv_2mortal(newSViv(actualHeight)));

MODULE = Newt		PACKAGE = Newt

newtComponent
newtCompactButton(left, top, text)
	int	left

Newt.xs  view on Meta::CPAN

	char **	text
	void **	data

void
newtListboxGetSelection(co)
	newtComponent	co
	PREINIT:
		int i;
		int numitems = 0;
		void **array;
	PPCODE:
		array = newtListboxGetSelection(co, &numitems);
		for(i = 0; i < numitems; i++) {
			XPUSHs(sv_2mortal(newSVsv((SV *)array[i])));
		}

void
newtListboxClearSelection(co)
	newtComponent	co

void

Newt.xs  view on Meta::CPAN

		RETVAL = newtRunForm(form);
	OUTPUT:
		RETVAL

void
newtFormRun(co)
	newtComponent	co
	PREINIT:
		struct newtExitStruct es;
		SV sv;
	PPCODE:
		newtFormRun(co, &es);
		XPUSHs(sv_2mortal(newSViv(es.reason)));
		if(es.reason == NEWT_EXIT_COMPONENT) {
			XPUSHs(sv_2mortal(sv_setref_pv(newSViv(0), 
						       "newtComponent",
						       (void*)es.u.co)));
		} else {
			XPUSHs(sv_2mortal(newSViv(es.u.key)));
		}
	



( run in 0.776 second using v1.01-cache-2.11-cpan-5511b514fd6 )