@Override
 protected void writeErrorSummaryMainText(
     FacesContext context, ResponseWriter w, FormLayout c, FacesMessage.Severity sev)
     throws IOException {
   w.startElement("h1", c); // $NON-NLS-1$
   String style = (String) getProperty(PROP_ERRORSUMMARYSTYLE);
   if (StringUtil.isNotEmpty(style)) {
     w.writeAttribute("style", style, null); // $NON-NLS-1$
   }
   String cls = (String) getProperty(PROP_ERRORSUMMARYCLASS);
   if (StringUtil.isNotEmpty(cls)) {
     w.writeAttribute("class", cls, null); // $NON-NLS-1$
   }
   String mainText = c.getErrorSummaryText();
   if (StringUtil.isEmpty(mainText)) {
     mainText = (String) getProperty(PROP_ERRORSUMMARYMAINTEXT);
   }
   writeErrorMessage(context, w, c, mainText);
   w.endElement("h1"); // $NON-NLS-1$
 }