updating jump to line
This commit is contained in:
2
.idea/editor.xml
generated
2
.idea/editor.xml
generated
@@ -19,7 +19,7 @@
|
|||||||
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppBoostFormatTooManyArgs/@EntryIndexedValue" value="WARNING" type="string" />
|
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppBoostFormatTooManyArgs/@EntryIndexedValue" value="WARNING" type="string" />
|
||||||
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppCStyleCast/@EntryIndexedValue" value="SUGGESTION" type="string" />
|
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppCStyleCast/@EntryIndexedValue" value="SUGGESTION" type="string" />
|
||||||
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppCVQualifierCanNotBeAppliedToReference/@EntryIndexedValue" value="WARNING" type="string" />
|
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppCVQualifierCanNotBeAppliedToReference/@EntryIndexedValue" value="WARNING" type="string" />
|
||||||
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppClassCanBeFinal/@EntryIndexedValue" value="HINT" type="string" />
|
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppClassCanBeFinal/@EntryIndexedValue" value="DO_NOT_SHOW" type="string" />
|
||||||
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppClassIsIncomplete/@EntryIndexedValue" value="WARNING" type="string" />
|
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppClassIsIncomplete/@EntryIndexedValue" value="WARNING" type="string" />
|
||||||
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppClassNeedsConstructorBecauseOfUninitializedMember/@EntryIndexedValue" value="WARNING" type="string" />
|
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppClassNeedsConstructorBecauseOfUninitializedMember/@EntryIndexedValue" value="WARNING" type="string" />
|
||||||
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppClassNeverUsed/@EntryIndexedValue" value="WARNING" type="string" />
|
<option name="/Default/CodeInspection/Highlighting/InspectionSeverities/=CppClassNeverUsed/@EntryIndexedValue" value="WARNING" type="string" />
|
||||||
|
|||||||
2
.idea/kte.iml
generated
2
.idea/kte.iml
generated
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<module classpath="CMake" type="CPP_MODULE" version="4">
|
<module classpath="CIDR" type="CPP_MODULE" version="4">
|
||||||
<component name="FacetManager">
|
<component name="FacetManager">
|
||||||
<facet type="Python" name="Python facet">
|
<facet type="Python" name="Python facet">
|
||||||
<configuration sdkName="" />
|
<configuration sdkName="" />
|
||||||
|
|||||||
@@ -2350,7 +2350,8 @@ cmd_newline(CommandContext &ctx)
|
|||||||
}
|
}
|
||||||
// Insert replacement if provided
|
// Insert replacement if provided
|
||||||
if (!with.empty()) {
|
if (!with.empty()) {
|
||||||
buf->insert_text(static_cast<int>(y), static_cast<int>(p), std::string_view(with));
|
buf->insert_text(static_cast<int>(y), static_cast<int>(p),
|
||||||
|
std::string_view(with));
|
||||||
if (u) {
|
if (u) {
|
||||||
buf->SetCursor(p, y);
|
buf->SetCursor(p, y);
|
||||||
u->Begin(UndoType::Insert);
|
u->Begin(UndoType::Insert);
|
||||||
@@ -2405,6 +2406,8 @@ cmd_newline(CommandContext &ctx)
|
|||||||
ctx.editor.SetStatus(err.empty() ? std::string("Failed to open ") + value : err);
|
ctx.editor.SetStatus(err.empty() ? std::string("Failed to open ") + value : err);
|
||||||
} else {
|
} else {
|
||||||
ctx.editor.SetStatus(std::string("Opened ") + value);
|
ctx.editor.SetStatus(std::string("Opened ") + value);
|
||||||
|
// Center the view on the cursor (e.g. if the buffer restored a cursor position)
|
||||||
|
cmd_center_on_cursor(ctx);
|
||||||
// Close the prompt so subsequent typing edits the buffer, not the prompt
|
// Close the prompt so subsequent typing edits the buffer, not the prompt
|
||||||
ctx.editor.CancelPrompt();
|
ctx.editor.CancelPrompt();
|
||||||
}
|
}
|
||||||
@@ -4202,7 +4205,8 @@ cmd_reflow_paragraph(CommandContext &ctx)
|
|||||||
// Replace paragraph lines via PieceTable-backed operations
|
// Replace paragraph lines via PieceTable-backed operations
|
||||||
for (std::size_t i = para_end; i + 1 > para_start; --i) {
|
for (std::size_t i = para_end; i + 1 > para_start; --i) {
|
||||||
buf->delete_row(static_cast<int>(i));
|
buf->delete_row(static_cast<int>(i));
|
||||||
if (i == 0) break; // prevent wrap on size_t
|
if (i == 0)
|
||||||
|
break; // prevent wrap on size_t
|
||||||
}
|
}
|
||||||
// Insert new lines starting at para_start
|
// Insert new lines starting at para_start
|
||||||
std::size_t insert_y = para_start;
|
std::size_t insert_y = para_start;
|
||||||
|
|||||||
@@ -73,6 +73,7 @@ TerminalFrontend::Init(Editor &ed)
|
|||||||
have_old_sigint_ = true;
|
have_old_sigint_ = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
3
main.cc
3
main.cc
@@ -192,8 +192,6 @@ main(int argc, const char *argv[])
|
|||||||
} else if (req_term) {
|
} else if (req_term) {
|
||||||
use_gui = false;
|
use_gui = false;
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
|
|
||||||
// Default depends on build target: kge defaults to GUI, kte to terminal
|
// Default depends on build target: kge defaults to GUI, kte to terminal
|
||||||
#if defined(KTE_DEFAULT_GUI)
|
#if defined(KTE_DEFAULT_GUI)
|
||||||
use_gui = true;
|
use_gui = true;
|
||||||
@@ -307,6 +305,7 @@ main(int argc, const char *argv[])
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool running = true;
|
bool running = true;
|
||||||
while (running) {
|
while (running) {
|
||||||
fe->Step(editor, running);
|
fe->Step(editor, running);
|
||||||
|
|||||||
Reference in New Issue
Block a user