6#using <System.Drawing.dll>
13 static IntPtr
begin(System::String^ name, System::Drawing::Color c);
14 static void end(IntPtr p);
21 ptr =
begin(name, System::Drawing::Color::Red);
26 IntPtr
ptr = IntPtr::Zero;
33 static std::string
convert(System::String^ s)
36 return std::string(
"");
39 System::Text::Encoding^ utf8 = System::Text::Encoding::UTF8;
40 array<byte>^ utf8path = utf8->GetBytes(s);
41 pin_ptr<byte> pinnedText = &utf8path[0];
42 const char* p = (
const char*)pinnedText;
44 auto r = std::string(p, utf8path->Length);
49 static String^
New(std::string s)
51 System::Text::Encoding^ utf8 = System::Text::Encoding::UTF8;
52 return gcnew System::String(s.c_str(), 0, (
int)s.length(), utf8);
Definition: SharpKmyCore.h:31
static String New(std::string s)
Definition: SharpKmyCore.h:49
static std::string convert(System::String^ s)
Definition: SharpKmyCore.h:33