Back to index

texmacs  1.0.7.15
Functions
typesetter.cpp File Reference
#include "Bridge/impl_typesetter.hpp"
#include "iterator.hpp"

Go to the source code of this file.

Functions

typesetter new_typesetter (edit_env &env, tree et, path ip)
void delete_typesetter (typesetter ttt)
static rectangles requires_update (rectangles log)
void notify_assign (typesetter ttt, path p, tree u)
void notify_insert (typesetter ttt, path p, tree u)
void notify_remove (typesetter ttt, path p, int nr)
void notify_split (typesetter ttt, path p)
void notify_join (typesetter ttt, path p)
void notify_assign_node (typesetter ttt, path p, tree_label op)
void notify_insert_node (typesetter ttt, path p, tree t)
void notify_remove_node (typesetter ttt, path p)
void exec_until (typesetter ttt, path p)
box typeset (typesetter ttt, SI &x1, SI &y1, SI &x2, SI &y2)
box typeset_as_document (edit_env env, tree t, path ip)

Function Documentation

Definition at line 33 of file typesetter.cpp.

                                   {
  tm_delete (ttt);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void exec_until ( typesetter  ttt,
path  p 
)

Definition at line 256 of file typesetter.cpp.

                                    {
  ttt->br->exec_until (p);
}

Here is the caller graph for this function:

typesetter new_typesetter ( edit_env env,
tree  et,
path  ip 
)

Definition at line 28 of file typesetter.cpp.

                                                 {
  return tm_new<typesetter_rep> (env, et, ip);
}

Here is the caller graph for this function:

void notify_assign ( typesetter  ttt,
path  p,
tree  u 
)

Definition at line 190 of file typesetter.cpp.

                                               {
  // cout << "Assign " << p << ", " << u << "\n";
  if (is_nil (p)) ttt->br= make_bridge (ttt, u, ttt->br->ip);
  else ttt->br->notify_assign (p, u);
}

Here is the call graph for this function:

void notify_assign_node ( typesetter  ttt,
path  p,
tree_label  op 
)

Definition at line 221 of file typesetter.cpp.

                                                           {
  // cout << "Assign node " << p << ", " << as_string (op) << "\n";
  tree t= subtree (ttt->br->st, p);
  int i, n= N(t);
  tree r (op, n);
  for (i=0; i<n; i++) r[i]= t[i];
  if (is_nil (p)) ttt->br= make_bridge (ttt, r, ttt->br->ip);
  else ttt->br->notify_assign (p, r);
}

Here is the call graph for this function:

void notify_insert ( typesetter  ttt,
path  p,
tree  u 
)

Definition at line 197 of file typesetter.cpp.

                                               {
  // cout << "Insert " << p << ", " << u << "\n";
  ttt->br->notify_insert (p, u);
}
void notify_insert_node ( typesetter  ttt,
path  p,
tree  t 
)

Definition at line 232 of file typesetter.cpp.

                                                    {
  // cout << "Insert node " << p << ", " << t << "\n";
  int i, pos= last_item (p), n= N(t);
  tree r (t, n+1);
  for (i=0; i<pos; i++) r[i]= t[i];
  r[pos]= subtree (ttt->br->st, path_up (p));
  for (i=pos; i<n; i++) r[i+1]= t[i];
  if (is_nil (path_up (p))) ttt->br= make_bridge (ttt, r, ttt->br->ip);
  else ttt->br->notify_assign (path_up (p), r);
}

Here is the call graph for this function:

void notify_join ( typesetter  ttt,
path  p 
)

Definition at line 215 of file typesetter.cpp.

                                     {
  // cout << "Join " << p << "\n";
  ttt->br->notify_join (p);
}
void notify_remove ( typesetter  ttt,
path  p,
int  nr 
)

Definition at line 203 of file typesetter.cpp.

                                               {
  // cout << "Remove " << p << ", " << nr << "\n";
  ttt->br->notify_remove (p, nr);
}
void notify_remove_node ( typesetter  ttt,
path  p 
)

Definition at line 244 of file typesetter.cpp.

                                            {
  // cout << "Remove node " << p << "\n";
  tree t= subtree (ttt->br->st, p);
  if (is_nil (path_up (p))) ttt->br= make_bridge (ttt, t, ttt->br->ip);
  else ttt->br->notify_assign (path_up (p), t);
}

Here is the call graph for this function:

void notify_split ( typesetter  ttt,
path  p 
)

Definition at line 209 of file typesetter.cpp.

                                      {
  // cout << "Split " << p << "\n";
  ttt->br->notify_split (p);
}
static rectangles requires_update ( rectangles  log) [static]

Definition at line 109 of file typesetter.cpp.

                                 {
  rectangles rs;
  while (!is_nil (log)) {
    rectangle r1= log->item;
    rectangle r2= log->next->item;
    if (r1 == rectangle (0, 0, 0, 0)) rs= rectangles (r2, rs);
    else if (r2 == rectangle (0, 0, 0, 0)) rs= rectangles (r1, rs);
    else if (r1 != r2) rs= rectangles (r1, rectangles (r2, rs));
    log= log->next->next;
  }
  return reverse (rs);
}

Here is the call graph for this function:

Here is the caller graph for this function:

box typeset ( typesetter  ttt,
SI x1,
SI y1,
SI x2,
SI y2 
)

Definition at line 261 of file typesetter.cpp.

                                                         {
  return ttt->typeset (x1, y1, x2, y2);
}

Here is the call graph for this function:

box typeset_as_document ( edit_env  env,
tree  t,
path  ip 
)

Definition at line 266 of file typesetter.cpp.

                                                    {
  env->style_init_env ();
  env->update ();
  typesetter ttt= new_typesetter (env, t, ip);
  box b= ttt->typeset ();
  delete_typesetter (ttt);
  return b;
}

Here is the call graph for this function:

Here is the caller graph for this function: