<commit_before>﻿using System.Runtime.InteropServices;
using System.Numerics;
using System;

namespace ImGuiNET
{
    /// <summary>
    /// Contains all of the exported functions from the native (c)imGui module.
    /// </summary>
    public static unsafe class ImGuiNative
    {
        private const string cimguiLib = "cimgui";

        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern NativeIO* igGetIO();

        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern NativeStyle* igGetStyle();

        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern DrawData* igGetDrawData();

        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igNewFrame();
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igNewLine();
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igRender();
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShutdown();
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShowUserGuide();
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShowStyleEditor(ref NativeStyle @ref);

        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShowDemoWindow(ref bool opened);
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShowMetricsWindow(ref bool opened);

        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShowStyleSelector(string label);
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShowFontSelector(string label);


        // Window
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        [return: MarshalAs(UnmanagedType.I1)]
        public static extern bool igBegin(string name, byte* p_opened, WindowFlags flags);
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        [return: MarshalAs(UnmanagedType.I1)]
        public static extern bool igBegin2(string name, byte* p_opened, Vector2 size_on_first_use, float bg_alpha, WindowFlags flags);
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]<commit_msg>Preserve old igBegin overloads for compatibility.<commit_after>﻿using System.Runtime.InteropServices;
using System.Numerics;
using System;

namespace ImGuiNET
{
    /// <summary>
    /// Contains all of the exported functions from the native (c)imGui module.
    /// </summary>
    public static unsafe class ImGuiNative
    {
        private const string cimguiLib = "cimgui";

        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern NativeIO* igGetIO();

        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern NativeStyle* igGetStyle();

        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern DrawData* igGetDrawData();

        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igNewFrame();
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igNewLine();
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igRender();
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShutdown();
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShowUserGuide();
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShowStyleEditor(ref NativeStyle @ref);

        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShowDemoWindow(ref bool opened);
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShowMetricsWindow(ref bool opened);

        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShowStyleSelector(string label);
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        public static extern void igShowFontSelector(string label);


        // Window
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        [return: MarshalAs(UnmanagedType.I1)]
        public static extern bool igBegin(string name, byte* p_opened, WindowFlags flags);
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        [return: MarshalAs(UnmanagedType.I1)]
        public static extern bool igBegin2(string name, byte* p_opened, Vector2 size_on_first_use, float bg_alpha, WindowFlags flags);
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        [return: MarshalAs(UnmanagedType.I1)]
        public static extern bool igBegin(string name, ref bool p_opened, WindowFlags flags);
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
        [return: MarshalAs(UnmanagedType.I1)]
        public static extern bool igBegin2(string name, ref bool p_opened, Vector2 size_on_first_use, float bg_alpha, WindowFlags flags);
        [DllImport(cimguiLib, CallingConvention = CallingConvention.Cdecl)]
{'fraction_non_alphanumeric': 0.08081674673987646, 'fraction_numerical': 0.002059025394646534, 'mean_word_length': 3.902439024390244, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1335004', 'n_tokens_mistral': 1679, 'n_tokens_neox': 1652, 'n_words': 402}