code: public void restoreState() {
          content.append("Q").append_i(separator);
          int idx = stateList.size() - 1;
          if (idx < 0)
              throw new IllegalPdfSyntaxException("Unbalanced save/restore state operators.");
          state = (GraphicState)stateList.get(idx);
          stateList.remove(idx);
      }
docs: Restores the graphic state. <CODE>saveState</CODE> and
  <CODE>restoreState</CODE> must be balanced.