eptr->lo_any.width = 0; eptr->lo_any.height = 0; eptr->lo_any.x_offset = 0; eptr->lo_any.y_offset = 0; eptr->lo_any.x = 0; eptr->lo_any.y = 0; eptr->lo_any.line_height = 0;
lo_NewElement(MWContext *context, lo_DocState *state, intn type, 		ED_Element *edit_element, intn edit_offset){	LO_Element *eptr;#ifdef MEMORY_ARENAS	int32 size;	switch(type)	{		case LO_TEXT:			size = sizeof(LO_TextStruct);			break;		case LO_LINEFEED:			size = sizeof(LO_LinefeedStruct);			break;		case LO_HRULE:			size = sizeof(LO_HorizRuleStruct);			break;		case LO_IMAGE:			size = sizeof(LO_ImageStruct);			break;		case LO_BULLET:			size = sizeof(LO_BulletStruct);			break;		case LO_FORM_ELE:			size = sizeof(LO_FormElementStruct);			break;		case LO_SUBDOC:			size = sizeof(LO_SubDocStruct);			break;		case LO_TABLE:			size = sizeof(LO_TableStruct);			break;		case LO_BUILTIN:			size = sizeof(LO_BuiltinStruct);			break;		case LO_CELL:			size = sizeof(LO_CellStruct);			break;		case LO_EMBED:			size = sizeof(LO_EmbedStruct);			break;#ifdef JAVA		case LO_JAVA:			size = sizeof(LO_JavaAppStruct);			break;#endif		case LO_EDGE:			size = sizeof(LO_EdgeStruct);			break;		case LO_OBJECT:			size = sizeof(LO_ObjectStruct);			break;		case LO_PARAGRAPH:			size = sizeof(LO_ParagraphStruct);			break;		case LO_CENTER:			size = sizeof(LO_CenterStruct);			break;		case LO_MULTICOLUMN:			size = sizeof(LO_MulticolumnStruct);			break;		case LO_TEXTBLOCK:			size = sizeof(LO_TextBlock);			break;		case LO_LIST:			size = sizeof(LO_ListStruct);			break;		case LO_DESCTITLE:			size = sizeof(LO_DescTitleStruct);			break;		case LO_DESCTEXT:			size = sizeof(LO_DescTextStruct);			break;		case LO_BLOCKQUOTE:			size = sizeof(LO_BlockQuoteStruct);			break;		case LO_LAYER:			size = sizeof(LO_LayerStruct);			break;		case LO_HEADING:			size = sizeof(LO_HeadingStruct);			break;		case LO_SPAN:			size = sizeof(LO_SpanStruct);			break;		case LO_DIV:			size = sizeof(LO_DivStruct);			break;		case LO_SPACER:			size = sizeof(LO_SpacerStruct);			break;		case LO_FLOAT:			size = sizeof(LO_FloatStruct);                        break;		case LO_SUPER:			size = sizeof(LO_SuperStruct);                        break;		case LO_SUB:			size = sizeof(LO_SubStruct);                        break;		default:			size = sizeof(LO_Any);			break;	}    if ( ! EDT_IS_EDITOR(context) ) {    	eptr = (LO_Element *)lo_MemoryArenaAllocate(state->top_state, size);    }    else {	    if (state->top_state->recycle_list != NULL)	    {		    eptr = state->top_state->recycle_list;		    state->top_state->recycle_list = eptr->lo_any.next;	    }	    else	    {            eptr = XP_NEW_ZAP(LO_Element);        }    }#else	/* sorry about all the asserts, in my debug version somehow state	 * becomes nil after a malloc failure. */#ifdef DEBUG	assert (state);#endif		if (state->top_state->recycle_list != NULL)	{		eptr = state->top_state->recycle_list;		state->top_state->recycle_list = eptr->lo_any.next;	}	else	{		eptr = XP_NEW(LO_Element);#ifdef DEBUG		assert (state);#endif	} #endif /* MEMORY_ARENAS */		if (eptr == NULL)	{#ifdef DEBUG		assert (state);#endif		state->top_state->out_of_memory = TRUE;	}	else	{		eptr->lo_any.next = NULL;		eptr->lo_any.prev = NULL;#ifdef EDITOR		eptr->lo_any.edit_element = NULL;		eptr->lo_any.edit_offset = 0;		if( EDT_IS_EDITOR(context) )        {            if( lo_EditableElement( type ) )		    {			    if( edit_element == 0 ){				    edit_element = state->edit_current_element;				    edit_offset = state->edit_current_offset;			    }			    EDT_SetLayoutElement( edit_element, 									    edit_offset,									    type,									    eptr );            } else if( edit_element && (type == LO_TABLE || type == LO_CELL) )            {                /* _TABLE_EXPERIMENT_  SAVE POINTER TO EDIT ELEMENT IN LO STRUCT */                eptr->lo_any.edit_element = edit_element;            }        }		state->edit_force_offset = FALSE;#endif	}	return(eptr);}