mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-04 03:58:47 +02:00
Log/Capture: Fixes for handling \n in strings. Improve the look of various widgets. Added LogSetNextTextDecoration helper. Fixup/amend dbaf74d75
.
For now removed LogRenderedTextNewLine() - it is eventually desirable but currently carries too much ambiguities, so reverted until we have a better system and test suite.
This commit is contained in:
@ -1654,6 +1654,10 @@ void ImGui::TableEndRow(ImGuiTable* table)
|
||||
if (table->CurrentColumn != -1)
|
||||
TableEndCell(table);
|
||||
|
||||
// Logging
|
||||
if (g.LogEnabled)
|
||||
LogRenderedText(NULL, "|");
|
||||
|
||||
// Position cursor at the bottom of our row so it can be used for e.g. clipping calculation. However it is
|
||||
// likely that the next call to TableBeginCell() will reposition the cursor to take account of vertical padding.
|
||||
window->DC.CursorPos.y = table->RowPosY2;
|
||||
@ -1890,6 +1894,14 @@ void ImGui::TableBeginCell(ImGuiTable* table, int column_n)
|
||||
SetWindowClipRectBeforeSetChannel(window, column->ClipRect);
|
||||
table->DrawSplitter.SetCurrentChannel(window->DrawList, column->DrawChannelCurrent);
|
||||
}
|
||||
|
||||
// Logging
|
||||
ImGuiContext& g = *GImGui;
|
||||
if (g.LogEnabled && !column->IsSkipItems)
|
||||
{
|
||||
LogRenderedText(&window->DC.CursorPos, "|");
|
||||
g.LogLinePosY = FLT_MAX;
|
||||
}
|
||||
}
|
||||
|
||||
// [Internal] Called by TableNextRow()/TableSetColumnIndex()/TableNextColumn()
|
||||
|
Reference in New Issue
Block a user