public Rect GetGuiRect(jxE g) { jxV vRect = g.AttrVar("Rect"); if (vRect == null) { vRect = g.AttrVar("Name"); } if (vRect == null) { //jDebug.jWARN(" attribute not found Rect : " + g.GetTagName()); return(new Rect(0, 0, 0, 0)); } if (vRect.GetEType() == nXML.EDataType.e_Rect) { return(vRect.GetRect()); } if (vRect.GetEType() != nXML.EDataType.e_string) { throw new System.Exception("xml : vRect.GetEType() != nXML.EDataType.e_string : " + m_Doc.m_name); } jxE eRect = m_eNamedRect.Find(vRect.Get_string()); if (eRect == null) { throw new System.Exception(m_Doc.m_name + " eRect==null"); } return(eRect.GetRect()); }
public string AttrOverride(string attribute_name) { jxA v = AttrVarOverride(attribute_name); if (v == null) { return(null); } if (!v.IsEType(nXML.EDataType.e_string)) { string sError = m_jxE.GetTagName() + "'s attribute<" + attribute_name + "> is not e_string : " + v.GetEType().ToString(); throw new System.Exception(sError); } return(v.Get_string()); }