"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/Edit/Replace/edit_select.cpp" between
TeXmacs-1.99.4-src.tar.gz and TeXmacs-1.99.5-src.tar.gz

About: GNU TeXmacs is a what-you-see-is-what-you-get scientific text editor, which was both inspired by TeX and GNU Emacs.

edit_select.cpp  (TeXmacs-1.99.4-src):edit_select.cpp  (TeXmacs-1.99.5-src)
skipping to change at line 651 skipping to change at line 651
path old_tp= tp; path old_tp= tp;
selection sel; selection_get (sel); selection sel; selection_get (sel);
go_to (sel->end); go_to (sel->end);
tree t= selection_get (); tree t= selection_get ();
go_to (sel->start); go_to (sel->start);
selection_set (key, t); selection_set (key, t);
go_to (old_tp); go_to (old_tp);
} }
} }
tree
edit_select_rep::selection_get (string key) {
tree t; string s;
(void) ::get_selection (key, t, s, selection_import);
return t;
}
void void
edit_select_rep::selection_paste (string key) { edit_select_rep::selection_paste (string key) {
tree t; string s; tree t; string s;
(void) ::get_selection (key, t, s, selection_import); (void) ::get_selection (key, t, s, selection_import);
if (inside_active_graphics ()) { if (inside_active_graphics ()) {
if (is_tuple (t, "texmacs", 3)) if (is_tuple (t, "texmacs", 3))
call ("graphics-paste", t[1]); call ("graphics-paste", t[1]);
return; return;
} }
if (is_tuple (t, "extern", 1)) { if (is_tuple (t, "extern", 1)) {
skipping to change at line 949 skipping to change at line 956
if (is_atomic (st) || if (is_atomic (st) ||
is_func (st, DOCUMENT) || is_func (st, DOCUMENT) ||
is_func (st, CONCAT) || is_func (st, CONCAT) ||
is_func (st, TFORMAT) || is_func (st, TFORMAT) ||
is_func (st, TABLE) || is_func (st, TABLE) ||
is_func (st, ROW) || is_func (st, ROW) ||
is_func (st, CELL) || is_func (st, CELL) ||
is_compound (st, "shown") || is_compound (st, "shown") ||
is_func (st, HIDDEN) || is_func (st, HIDDEN) ||
is_compound (st, "shared") || is_compound (st, "shared") ||
is_compound (st, "slide") ||
is_compound (st, "with-screen-color") ||
up_flag) up_flag)
return focus_search (path_up (p), skip_flag, false); return focus_search (path_up (p), skip_flag, false);
return p; return p;
} }
path path
edit_select_rep::focus_get (bool skip_flag) { edit_select_rep::focus_get (bool skip_flag) {
//cout << "Search focus " << focus_p << ", " << skip_flag << "\n"; //cout << "Search focus " << focus_p << ", " << skip_flag << "\n";
if (!is_nil (focus_p)) if (!is_nil (focus_p))
return focus_search (focus_p, skip_flag, false); return focus_search (focus_p, skip_flag, false);
if (selection_active_any ()) if (selection_active_any ())
return focus_search (selection_get_path (), skip_flag, false); return focus_search (selection_get_path (), skip_flag, false);
else else {
tree st= subtree (et, path_up (tp));
if (is_compound (st, "draw-over")) skip_flag= false;
if (is_compound (st, "draw-under")) skip_flag= false;
if (is_compound (st, "float")) skip_flag= false;
if (is_compound (st, "footnote")) skip_flag= false;
return focus_search (path_up (tp), skip_flag, true); return focus_search (path_up (tp), skip_flag, true);
}
} }
/****************************************************************************** /******************************************************************************
* Alternative selections * Alternative selections
******************************************************************************/ ******************************************************************************/
void void
edit_select_rep::set_alt_selection (string name, range_set sel) { edit_select_rep::set_alt_selection (string name, range_set sel) {
if (alt_sels[name] != sel) { if (alt_sels[name] != sel) {
alt_sels (name)= sel; alt_sels (name)= sel;
 End of changes. 4 change blocks. 
1 lines changed or deleted 16 lines changed or added

Home  |  About  |  All  |  Newest  |  Fossies Dox  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTPS