Dear ImGui for Go - GitHub

文章推薦指數: 80 %
投票人數:10人

Go wrapper library for "Dear ImGui" (https://github.com/ocornut/imgui) - GitHub - inkyblackness/imgui-go: Go wrapper library for "Dear ImGui" ... Skiptocontent {{message}} inkyblackness / imgui-go Public Notifications Star 620 Fork 73 Gowrapperlibraryfor"DearImGui"(https://github.com/ocornut/imgui) Viewlicense 620 stars 73 forks Star Notifications Code Issues 1 Pullrequests 1 Discussions Actions Security Insights More Code Issues Pullrequests Discussions Actions Security Insights main Branches Tags Couldnotloadbranches Nothingtoshow Loading {{refName}} default Couldnotloadtags Nothingtoshow {{refName}} default Loading 4 branches 39 tags Code Loading Latestcommit dertseha Updatescreenshotfor1.85 … ebfae41 Nov17,2021 Updatescreenshotfor1.85 ebfae41 Gitstats 624 commits Files Permalink Failedtoloadlatestcommitinformation. Type Name Latestcommitmessage Committime .github/workflows AddGo1.17totestmatrix Sep29,2021 _licenses Addsmallscripttomakeupdatingimguialittleeasier Apr25,2021 assets Updatescreenshotfor1.85 Nov17,2021 imgui Updateimguitov1.85 Oct18,2021 scripts appliedunifiedstylefornativecode May19,2020 wrapper Mergepullrequest#160fromneclepsio/noextra Nov17,2021 .gitignore Reducedignorerules.Onupgrade,copyonlynecessaryfiles,nothide… May21,2020 .golangci.yml removedeprecatedserviceblock Nov25,2020 AllocatedGlyphRanges.go fixedbuilderroron32bitsystemswithpointer-to-slicecasts Jun14,2020 AllocatedGlyphRanges_test.go switchtov4 Feb21,2021 Assert.go CallingGoassertonlyifconditionactuallyfailsinCland May20,2020 CONTRIBUTING.md addnoteaboutC++formatting Dec28,2020 Color.go Keeplinterhappy Aug27,2021 Condition.go removediotabasedconstantdefinitionsinforflagtypes Feb16,2021 Context.go Removed"Wrapper"suffixfromfilesin"wrapper"directory May4,2020 Context_test.go removedunnecessarysprintf May17,2020 DragDrop.go FixesforColorButton Aug27,2021 DrawCommand.go ExposeVtxOffsettoallowbackendstorendermorethan64kvertices May29,2021 DrawData.go Addgettersfordrawdatasizes Jul7,2021 DrawData_test.go switchtov4 Feb21,2021 DrawList.go Mergepullrequest#148fromptxmac/imgui-1.82 Apr30,2021 Focus.go Enabledsomelinter(mostnotably:godot)andfixedissues May20,2020 Font.go fix:don'ttakenullcharintoaccountinsizecalculation Jan18,2021 FontAtlas.go Fixedlintererrors Feb13,2021 FontConfig.go addedSetGlyphOffsetX()andSetGlyphOffsetY()toFontConfigtype. Mar17,2021 FreeType.go addnewfreetypeflagandrenametextoverwriteflag Apr21,2021 GlyphRanges.go fixedbuilderroron32bitsystemswithpointer-to-slicecasts Jun14,2020 IO.go Updateimguitov1.85 Oct18,2021 InputTextCallbackData.go addedInputTextFlagstype Feb16,2021 LICENSE update Jul25,2018 Layout.go Implementcomments Sep28,2021 ListClipper.go trytogetridoflintererrors Jan30,2021 Main.go re-runformattingonfile Nov25,2020 Main_test.go Updateimguitov1.85 Oct18,2021 PackedColor.go avoidingmagicconstants May17,2020 Popup.go fixedBeginPopupVandBeginPopupModalVhavingincorrectflagstype;+… Feb24,2021 README.md Fixreadmecontent Nov17,2021 Scroll.go Mergebranch'master'intoupstream_master Jan30,2021 State.go Updateimguitov1.85 Oct18,2021 Style.go Updatetableconstantsto1.84 Aug27,2021 Tables.go Updatetableconstantsto1.84 Aug27,2021 TextureID.go Removed"Wrapper"suffixfromfilesin"wrapper"directory May4,2020 Vectors.go Removed"Wrapper"suffixfromfilesin"wrapper"directory May4,2020 Vectors_test.go switchtov4 Feb21,2021 Widgets.go RefactortomoveColorwidgetsinseparatefiles Aug27,2021 Window.go Mergepullrequest#160fromneclepsio/noextra Nov17,2021 WrapperConverter.go fixedbuilderroron32bitsystemswithpointer-to-slicecasts Jun14,2020 WrapperConverter_test.go deliberatelyallowingteststoaccessinternals May17,2020 doc.go #40fixedexamplesreference May25,2019 go.mod switchtov4 Feb21,2021 go.sum addedmoduleinformation Feb3,2019 update_imgui.sh Addsmallscripttomakeupdatingimguialittleeasier Apr25,2021 wrapper.cpp RefactortomoveColorwidgetsinseparatefiles Aug27,2021 wrapper.go Upgradeimguitov1.82 Apr6,2021 Viewcode DearImGuiforGo APInaming APIphilosophy Versionphilosophy Examples Extras FreeTypefontrendering Alternatives License README.md DearImGuiforGo ThislibraryisaGowrapperforDearImGui. Thiswrapperstartedasaspecial-purposewrapperforusewithinInkyBlackness. However,itisself-containedandcanbeusedforotherpurposesaswell. Thiswrapperis hand-crafted,forGo documented versioned withportedexamplesinaseparaterepository(seebelow) APInaming NamesoftypesandfunctionsfollowcloselythoseofDearImGui. Forfunctionsthathaveoptionalparameters,thefollowingschemaisapplied: Thereisthe"verbose"variant,followedbytheletterV,suchasButtonV(idstring,sizeVec2)bool Nexttoitthereisthe"idiomatic"variant,withoutanyoptionalparameter,suchasButton(idstring)bool. Theidiomaticvariantcallstheverbosevariantwiththedefaultvaluesfortheoptionalparameters. Functionsthatdon'thaveoptionalparametersdon'tcomeinaverbosevariant. TheDearImGuifunctionsIO()andStyle()havebeenrenamedtobeCurrentIO()andCurrentStyle(). Thiswasdonebecausetheirreturnedtypeshavethesamename,causinganameclash. WiththeCurrentprefix,theyalsobetterdescribewhattheyreturn. APIphilosophy ThislibrarydoesnotintendtoexportallthefunctionsofthewrappedDearImGui.Thefollowingfilterappliesasaruleofthumb: Functionsmarkedas"obsolete"arenotavailable.(ThecorrespondingCcodeisn'tevencompiled-disabledbydefine) "Shortcut"Functions,whichcombinelanguagefeaturesand/orotherDearImGuifunctions,arenotavailable.PrimeexamplearetheText*()functionsforinstance:Textformattingshouldbedonewithfmt.Sprintf(),andstyleformattingwiththecorrespondingPush/Popfunctions. FunctionsthatarenotneededbyInkyBlacknessareignored.Thisdoesn'tmeanthattheycan'tbeinthewrapper,theyaresimplynotapriority.Feelfreetoproposeanimplementationormakeapullrequest,respectingthepreviouspoints:) Versionphilosophy ThislibrarydoesnotmirrortheversionsofthewrappedDearImGui.Thesemanticversioningofthiswrapperisdefinedas: Majorchanges:(Breaking)changesinAPIorbehaviour.TypicallydonethroughchangesinDearImGui. Minorchanges:ExtensionsinAPI.TypicallydonethroughsmallversionincrementsofDearImGuiand/orexposingfurtherfeaturesinacompatibleway. Patchchanges:Bugfixes-eitherinthewrapperorthewrappedDearImGui,giventhattheAPI&behaviourremainsthesame. Atthemoment,thislibraryusesversion1.85ofDearImGui. Examples Aseparaterepositorywascreatedtohostportedexamplesandreferenceimplementations. Seerepositoryinkyblackness/imgui-go-examples. ItcontainsreferenceimplementationsforlibrariessuchasGLFW3andSDL2,usingOpenGL. Thescreenshotabovewascreatedwithsuchanexample. Extras FreeTypefontrendering IftheFreeTypelibraryisavailableforyourplatform,youcanenableusingitwiththebuildtagimguifreetype-asin gobuild-tags="imguifreetype" ThisextraisbasedonthereferenceimplementationfromDearImGui. Ifyousetthebuildtag,yetthecorrespondingsupporthasnotbeenaddedtothelibrary,youwillreceiveabuilderror. Contributionstosupportmorebuildenvironmentsarehappilyaccepted.SeefileFreeType.go. IfyouaretryingtodothisonMSWindowswithMinGWandreceiveanerrorlike pkg-config:exec:"pkg-config":executablefilenotfoundin%PATH%, refertoonlineguidesonhowtoaddthistoyourinstallation. Alternatives Beforethisprojectwascreated,thefollowingalternativeswereconsidered-andignored: kdrag0n/go-imgui(nolongeravailable).Reasonsfordismissalattimeofdecision: Auto-generatedbloat,whichdoesn'thelp WasusingoldAPI(1.5x) Didnotcompile Projectappearedtobeabandoned Extrawurst/cimgui.Reasonsfordismissalattimeofdecision: WasusingoldAPI(1.5x),1.6xwasattempted Apparentlysemi-exposedtheC++API,especiallythroughthestructures Addingthisaddsanotherdependency Note:cimguihassinceswitchedtoanauto-generatedmethod.Youcanusethatinsteadofthismanuallycuratedwrapperhere. License TheprojectisavailableunderthetermsoftheNewBSDLicense(seeLICENSEfile). Thelicensesofincludedsourcesarestoredinthe_licensesfolder. About Gowrapperlibraryfor"DearImGui"(https://github.com/ocornut/imgui) Topics go golang wrapper gui ui toolkit imgui dear-imgui hacktoberfest Resources Readme License Viewlicense Releases 39 v4.4.0-updateto1.85 Latest Nov17,2021 +38releases Packages0 Nopackagespublished Usedby25 +17 Contributors27 +16contributors Languages C++ 81.9% C 10.1% Go 8.0% Youcan’tperformthatactionatthistime. Yousignedinwithanothertaborwindow.Reloadtorefreshyoursession. Yousignedoutinanothertaborwindow.Reloadtorefreshyoursession.



請為這篇文章評分?