how about this
This commit is contained in:
parent
60bc604a93
commit
0c4f427adf
|
@ -66,9 +66,12 @@ internal class Viewer {
|
||||||
|
|
||||||
if (ImGui.TableSetColumnIndex(1) && this._idx > -1 && this._idx < nearby.Count) {
|
if (ImGui.TableSetColumnIndex(1) && this._idx > -1 && this._idx < nearby.Count) {
|
||||||
var message = nearby[this._idx];
|
var message = nearby[this._idx];
|
||||||
var size = ImGui.CalcTextSize(message.Text, ImGui.GetContentRegionAvail().X);
|
var size = ImGui.CalcTextSize(message.Text, ImGui.GetContentRegionAvail().X).Y;
|
||||||
|
size += ImGui.GetStyle().ItemSpacing.Y * 2;
|
||||||
|
size += ImGui.CalcTextSize("A").Y;
|
||||||
|
size += ImGuiHelpers.GetButtonSize("A").Y;
|
||||||
var height = ImGui.GetContentRegionAvail().Y;
|
var height = ImGui.GetContentRegionAvail().Y;
|
||||||
ImGui.Dummy(new Vector2(1, height / 2 - size.Y / 2 - ImGui.GetStyle().ItemSpacing.Y));
|
ImGui.Dummy(new Vector2(1, height / 2 - size / 2 - ImGui.GetStyle().ItemSpacing.Y));
|
||||||
|
|
||||||
ImGui.PushTextWrapPos();
|
ImGui.PushTextWrapPos();
|
||||||
ImGui.TextUnformatted(message.Text);
|
ImGui.TextUnformatted(message.Text);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user