Example #1
0
        }/* stream_mssg_off */

        /*
         * z_output_stream, open or close an output stream.
         *
         *	zargs[0] = stream to open (positive) or close (negative)
         *	zargs[1] = address to redirect output to (stream 3 only)
         *	zargs[2] = width of redirected output (stream 3 only, optional)
         *
         */

        internal static void z_output_stream()
        {
            Buffer.flush_buffer();

            switch ((short)Process.zargs[0])
            {
            case 1: main.ostream_screen = true;
                break;

            case -1: main.ostream_screen = false;
                break;

            case 2: if (!main.ostream_script)
                {
                    Files.script_open();
                }
                break;

            case -2: if (main.ostream_script)
                {
                    Files.script_close();
                }
                break;

            case 3: Redirect.memory_open(Process.zargs[1], Process.zargs[2], Process.zargc >= 3);
                break;

            case -3: Redirect.memory_close();
                break;

            case 4: if (!main.ostream_record)
                {
                    Files.record_open();
                }
                break;

            case -4: if (main.ostream_record)
                {
                    Files.record_close();
                }
                break;
            }
        }/* z_output_stream */
Example #2
0
        }/* stream_word */

        /*
         * stream_new_line
         *
         * Send a newline to the output streams.
         *
         */

        internal static void stream_new_line()
        {
            if (main.ostream_memory && !main.message)
            {
                Redirect.memory_new_line();
            }

            else
            {
                if (main.ostream_screen)
                {
                    Screen.screen_new_line();
                }
                if (main.ostream_script && main.enable_scripting)
                {
                    Files.script_new_line();
                }
                if (main.enable_scripting)
                {
                    os_.scrollback_char('\n');
                }
            }
        }/* stream_new_line */
Example #3
0
        }/* stream_char */

        /*
         * stream_word
         *
         * Send a string of characters to the output streams.
         *
         */

        internal static void stream_word(zword[] s)
        {
            if (main.ostream_memory && !main.message)
            {
                Redirect.memory_word(s);
            }

            else
            {
                if (main.ostream_screen)
                {
                    Screen.screen_word(s);
                }
                if (main.ostream_script && main.enable_scripting)
                {
                    Files.script_word(s);
                }
                if (main.enable_scripting)
                {
                    Stream.scrollback_word(s);
                }
            }
        }/* stream_word */