diff --git a/src/source.cc b/src/source.cc index 8c62866..a11a531 100644 --- a/src/source.cc +++ b/src/source.cc @@ -1472,10 +1472,12 @@ bool Source::ClangViewParse::on_key_press_event(GdkEventKey* key) { iter=get_buffer()->get_insert()->get_iter(); auto found_iter=iter; if(find_open_expression_symbol(iter, start_of_sentence_iter, found_iter)) { - auto offset=found_iter.get_line_offset(); - tabs.clear(); - for(int c=0;cinsert_at_cursor("\n"+tabs+tab); diff --git a/src/window.cc b/src/window.cc index 343fda6..3743727 100644 --- a/src/window.cc +++ b/src/window.cc @@ -513,8 +513,13 @@ void Window::new_cpp_project_dialog() { Singleton::terminal()->print("Error: "+cpp_main_path.string()+" already exists.\n"); return; } + auto tab_char=Singleton::Config::source()->default_tab_char; + auto tab_size=Singleton::Config::source()->default_tab_size; + std::string tab; + for(unsigned c=0;c