page-eject-item: Factor out of text_item.
[pspp] / src / output / spv / spv-writer.c
index 4883ebf5ba36477cff3fa7bcf90a696a93a74d5f..12f3ec70dff5bcff23cf6be7c4b54c09e362f367 100644 (file)
@@ -294,9 +294,6 @@ void
 spv_writer_put_text (struct spv_writer *w, const struct text_item *text,
                      const char *command_id)
 {
-  if (text->type == TEXT_ITEM_EJECT_PAGE)
-    w->need_page_break = true;
-
   bool initial_depth = w->heading_depth;
   if (!initial_depth)
     spv_writer_open_file (w);
@@ -325,6 +322,12 @@ spv_writer_put_text (struct spv_writer *w, const struct text_item *text,
   if (!initial_depth)
     spv_writer_close_file (w, "");
 }
+
+void
+spv_writer_eject_page (struct spv_writer *w)
+{
+  w->need_page_break = true;
+}
 \f
 #define H TABLE_HORZ
 #define V TABLE_VERT