Back to index

texmacs  1.0.7.15
Defines | Functions | Variables
prompt.cpp File Reference
#include <iostream>

Go to the source code of this file.

Defines

#define DATA_BEGIN   ((char) 2)
#define DATA_END   ((char) 5)
#define DATA_ESCAPE   ((char) 27)

Functions

void next_input ()
int main ()

Variables

static int counter = 0

Define Documentation

#define DATA_BEGIN   ((char) 2)

Definition at line 15 of file prompt.cpp.

#define DATA_END   ((char) 5)

Definition at line 16 of file prompt.cpp.

#define DATA_ESCAPE   ((char) 27)

Definition at line 17 of file prompt.cpp.


Function Documentation

int main ( )

Definition at line 30 of file prompt.cpp.

        {
  cout << DATA_BEGIN << "verbatim:";
  cout << "A LaTeX -> TeXmacs converter";
  next_input ();
  cout << DATA_END;
  cout.flush ();

  while (true) {
    char buffer[100];
    cin.getline (buffer, 100, '\n');
    cout << DATA_BEGIN << "verbatim:";
    cout << DATA_BEGIN;
    cout << "latex:$" << buffer << "$";
    cout << DATA_END;
    next_input ();
    cout << DATA_END;
    cout.flush ();
  }
  return 0;
}

Here is the call graph for this function:

void next_input ( )

Definition at line 22 of file prompt.cpp.

              {
  counter++;
  cout << DATA_BEGIN << "prompt#";
  cout << "Input " << counter << "] ";
  cout << DATA_END;
}

Variable Documentation

int counter = 0 [static]

Definition at line 19 of file prompt.cpp.