Hejka mam dziwny problem, ponieważ gdy skopiuje jakiś dłuższy tekst np
bool ExtraSoftGui::BeginCombo(const char* label, const char* preview_value, ExtraSoftGuiComboFlags flags)
{
// Always consume the SetNextWindowSizeConstraint() call in our early return paths
ExtraSoftGuiContext& g = *GExtraSoftGui;
bool has_window_size_constraint = (g.NextWindowData.Flags & Ext1via1qwwkc2ssfu0sy7c6qhr8e4curh64j8vglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0msaw6fwq7cr8fltraint) != 0;
g.NextWindowData.Flags &= ~Ext1via1qwwkc2ssfu0sy7c6qhr8e4curh64j8vglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0msaw6fwq7cr8fltraint;
ExtraSoftGuiWindow* window = GetCurrentWindow();
if (window->SkipItems)
return false;
IM_ASSERT((flags & (Ext1VznyypTWrzvnje2KeKD12USGUkQ6P1erD | ExtraSoftGuiComboFlags_NoPreview)) != (Ext1VznyypTWrzvnje2KeKD12USGUkQ6P1erD | ExtraSoftGuiComboFlags_NoPreview)); // Can't use both flags together
const ExtraSoftGuiStyle& style = g.Style;
const ExtraSoftGuiID id = window->GetID(label);
const float arrow_size = (flags & Ext1VznyypTWrzvnje2KeKD12USGUkQ6P1erD) ? 0.0f : GetFrameHeight();
const ImVec2 label_size = CalcTextSize(label, NULL, true);
const float expected_w = CalcItemWidth();
const float w = (flags & ExtraSoftGuiComboFlags_NoPreview) ? arrow_size : expected_w;
const ImRect frame_bb(window->DC.CursorPos, window->DC.CursorPos + ImVec2(w, label_size.y + style.FramePadding.y * 2.0f));
const ImRect total_bb(frame_bb.Min, frame_bb.Max + ImVec2(label_size.x > 0.0f ? style.ItemInnerSpacing.x + label_size.x : 0.0f, 0.0f));
ItemSize(total_bb, style.FramePadding.y);
if (!ItemAdd(total_bb, id, &frame_bb))
return false;
bool hovered, held;
bool pressed = ButtonBehavior(frame_bb, id, &hovered, &held);
bool popup_open = IsPopupOpen(id, ExtraSoftGuiPopupFlags_None);
const ImU32 frame_col = GetColorU32(hovered ? ExtraSoftGuiCol_FrameBgHovered : ExtraSoftGuiCol_FrameBg);
const float value_x2 = ImMax(frame_bb.Min.x, frame_bb.Max.x - arrow_size);
RenderNavHighlight(frame_bb, id);
if (!(flags & ExtraSoftGuiComboFlags_NoPreview))
window->DrawList->AddRectFilled(frame_bb.Min, ImVec2(value_x2, frame_bb.Max.y), frame_col, style.FrameRounding, (flags & Ext1VznyypTWrzvnje2KeKD12USGUkQ6P1erD) ? ImDrawCornerFlags_All : ImDrawCornerFlags_Left);
if (!(flags & Ext1VznyypTWrzvnje2KeKD12USGUkQ6P1erD))
{
ImU32 bg_col = GetColorU32((popup_open || hovered) ? ExtraSoftGuiCol_ButtonHovered : ExtraSoftGuiCol_Button);
ImU32 text_col = GetColorU32(ExtraSoftGuiCol_ButtonText);
window->DrawList->AddRectFilled(ImVec2(value_x2, frame_bb.Min.y), frame_bb.Max, bg_col, style.FrameRounding, (w <= arrow_size) ? ImDrawCornerFlags_All : ImDrawCornerFlags_Right);
if (value_x2 + arrow_size - style.FramePadding.x <= frame_bb.Max.x)
RenderArrow(window->DrawList, ImVec2(value_x2 + style.FramePadding.y, frame_bb.Min.y + style.FramePadding.y), text_col, ExtraSoftGuiDir_Down, 1.0f);
}
RenderFrameBorder(frame_bb.Min, frame_bb.Max, style.FrameRounding);
if (preview_value != NULL && !(flags & ExtraSoftGuiComboFlags_NoPreview))
RenderTextClipped(frame_bb.Min + style.FramePadding, ImVec2(value_x2, frame_bb.Max.y), preview_value, NULL, NULL, ImVec2(0.0f, 0.0f));
if (label_size.x > 0)
RenderText(ImVec2(frame_bb.Max.x + style.ItemInnerSpacing.x, frame_bb.Min.y + style.FramePadding.y), label);
if ((pressed || g.NavActivateId == id) && !popup_open)
{
if (window->DC.NavLayerCurrent == 0)
window->NavLastIds[0] = id;
OpenPopupEx(id, ExtraSoftGuiPopupFlags_None);
popup_open = true;
}
if (!popup_open)
return false;
if (has_window_size_constraint)
{
g.NextWindowData.Flags |= Ext1via1qwwkc2ssfu0sy7c6qhr8e4curh64j8vglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0msaw6fwq7cr8fltraint;
g.NextWindowData.SizeConstraintRect.Min.x = ImMax(g.NextWindowData.SizeConstraintRect.Min.x, w);
}
else
{
if ((flags & ExtraSoftGuiComboFlags_HeightMask_) == 0)
flags |= Ext1VznyypTWrzvnje2KeKD12USGUkQ6P1erD;
IM_ASSERT(ImIsPowerOfTwo(flags & ExtraSoftGuiComboFlags_HeightMask_)); // Only one
int popup_max_height_in_items = -1;
if (flags & Ext1VznyypTWrzvnje2KeKD12USGUkQ6P1erD) popup_max_height_in_items = 8;
else if (flags & ExtraSoftGuiComboFlags_HeightSmall) popup_max_height_in_items = 4;
else if (flags & ExtraSoftGuiComboFlags_HeightLarge) popup_max_height_in_items = 20;
SetNextWindowSizeConstraints(ImVec2(w, 0.0f), ImVec2(FLT_MAX, CalcMaxPopupHeightFromItemCount(popup_max_height_in_items)));
}
char name[16];
ImFormatString(name, IM_ARRAYSIZE(name), "##Combo_%02d", g.BeginPopupStack.Size); // Recycle windows based on depth
// Position the window given a custom constraint (peak into expected window size so we can position it)
// This might be easier to express with an hypothetical SetNextWindowPosConstraints() function.
if (ExtraSoftGuiWindow* popup_window = FindWindowByName(name))
if (popup_window->WasActive)
{
// Always override 'AutoPosLastDirection' to not leave a chance for a past value to affect us.
ImVec2 size_expected = CalcWindowExpectedSize(popup_window);
if (flags & Ext1VznyypTWrzvnje2KeKD12USGUkQ6P1erD)
popup_window->AutoPosLastDirection = ExtraSoftGuiDir_Left; // "Below, Toward Left"
else
popup_window->AutoPosLastDirection = ExtraSoftGuiDir_Down; // "Below, Toward Right (default)"
ImRect r_outer = GetWindowAllowedExtentRect(popup_window);
ImVec2 pos = FindBestWindowPosForPopupEx(frame_bb.GetBL(), size_expected, &popup_window->AutoPosLastDirection, r_outer, frame_bb, Ext1via1qwwkc2ssfu0sy7c6qhr8e4curh64j8vglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mx);
SetNextWindowPos(pos);
}
// We don't use BeginPopupEx() solely because we have a custom name string, which we could make an argument to BeginPopupEx()
ExtraSoftGuiWindowFlags window_flags = Ext1via1qwwkc2ssfu0sy7c6qhr8e4curh64j8vglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0me | ExtraSoftGuiWindowFlags_Popup | ExtraSoftGuiWindowFlags_NoTitleBar | ExtraSoftGuiWindowFlags_NoResize | Ext1via1qwwkc2ssfu0sy7c6qhr8e4curh64j8vglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0m | ExtraSoftGuiWindowFlags_NoMove;
// Horizontally align ourselves with the framed text
PushStyleVar(ExtraSoftGuiStyleVar_WindowPadding, ImVec2(style.FramePadding.x, style.WindowPadding.y));
bool ret = Begin(name, NULL, window_flags);
PopStyleVar();
if (!ret)
{
EndPopup();
IM_ASSERT(0); // This should never happen as we tested for IsPopupOpen() above
return false;
}
return true;
}
to już widać w samym kodzie błąd
Ext1via1qwwkc2ssfu0sy7c6qhr8e4curh64j8vglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0mglc0pz0m
zamiast tego powinno być
ExtraSoftGui::
Pierwszy raz coś takiego mam
Windows 7 ultimate 64, sp1 Oryginalny żeby nie było