-/* Drivers currently registered with output_driver_register(). */
-static struct llx_list drivers = LLX_INITIALIZER (drivers);
+/* A stack of output engines.. */
+static struct output_engine *engine_stack;
+static size_t n_stack, allocated_stack;
+
+static struct output_engine *
+engine_stack_top (void)
+{
+ assert (n_stack > 0);
+ return &engine_stack[n_stack - 1];
+}
+
+void
+output_engine_push (void)
+{
+ struct output_engine *e;
+
+ if (n_stack >= allocated_stack)
+ engine_stack = x2nrealloc (engine_stack, &allocated_stack,
+ sizeof *engine_stack);