enum CodeObjectType { typeClass, typeData, typeMethod, typeEvent, typeProperty, typeNameSpace, typeDataType, typeEnumValue, typeDataPrivate, typeMethodPrivate, typePropertyPrivate };
-
-static FileFilter fileFilters[] =
-{
- {
- "eC Shared Library files (*.dll, *.so, *.dylib)",
- "dll, so, dylib"
- },
- {
- "eC Symbol files (*.sym)",
- "sym"
- }
-};
-
static char * iconNames[CodeObjectType] =
{
"<:ecere>constructs/class.png",
{
if(type._class.registered)
{
- char hex[10];
- sprintf(hex, "%08x", type._class.registered);
+ char hex[20];
+ sprintf(hex, "%p", type._class.registered);
strcat(string, "<a href=\"api://");
strcat(string, hex);
strcat(string, "\" style=\"text-decoration: none;\">");
delete contents;
}
if(editing && !contents)
- contents = CopyString("[Add Text]");
+ contents = CopyString($"[Add Text]");
return contents;
}
ns = ns->parent;
}
// Generate Class Page
- f.Printf("<HTML><HEAD><TITLE>API Reference</TITLE></HEAD>\n<BODY><FONT SIZE=\"3\">\n");
+ f.Printf($"<HTML><HEAD><TITLE>API Reference</TITLE></HEAD>\n<BODY><FONT SIZE=\"3\">\n");
if(nsName[0])
{
f.Printf("<FONT FACE=\"Arial\" SIZE=\"6\">%s</FONT><br><br>\n", nsName );
tag = (uint)nameSpace;
- f.Printf("Module: <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a><br>\n", (module && module.name) ? module : null, (!module || !module.name || !strcmp(nsName, "ecere::com")) ? "ecereCOM" : module.name);
+ f.Printf($"Module: <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a><br>\n", (module && module.name) ? module : null, (!module || !module.name || !strcmp(nsName, "ecere::com")) ? "ecereCOM" : module.name);
}
else
{
tag = (uint)((!module || !module.name || !strcmp(nsName, "ecere::com") ? null : module));
- f.Printf("<FONT FACE=\"Arial\" SIZE=\"6\">Module %s</FONT><br>\n", (!module || !module.name || !strcmp(nsName, "ecere::com")) ? "ecereCOM" : module.name);
+ f.Printf($"<FONT FACE=\"Arial\" SIZE=\"6\">Module %s</FONT><br>\n", (!module || !module.name || !strcmp(nsName, "ecere::com")) ? "ecereCOM" : module.name);
}
nsName[0] = 0;
ns = ns->parent;
}
if(nsName[0])
- f.Printf("Parent namespace: <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a><br>\n", nameSpace->parent, nsName);
+ f.Printf($"Parent namespace: <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a><br>\n", nameSpace->parent, nsName);
f.Printf("<br>");
{
char * desc = ReadDoc(module, nameSpaceDoc, nameSpace, description, null);
if(desc)
{
- f.Printf("<H3>Description</H3><br><br>\n");
+ f.Printf($"<H3>Description</H3><br><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
char * desc = ReadDoc(module, nameSpaceDoc, ns, description, null);
if(first)
{
- f.Printf("<H3>Sub Namespaces</H3><br><br>\n");
+ f.Printf($"<H3>Sub Namespaces</H3><br><br>\n");
f.Printf("<TABLE >\n");
first = false;
}
f.Printf("<TR>");
- f.Printf("<TD valign=top height=22 nowrap=1><img valign=center src=\"%s\"> <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a></TD>", iconNames[typeNameSpace], ns, ns->name);
+ f.Printf("<TD valign=top height=22 nowrap=1><img valign=center src=\"%s\"> <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a></TD>", iconNames[typeNameSpace], ns, ns->name);
if(desc)
{
if(editing)
if(first)
{
- f.Printf("<a name=Classes></a><H3>Classes</H3><br><br>\n");
+ f.Printf($"<a name=Classes></a><H3>Classes</H3><br><br>\n");
f.Printf("<TABLE >\n");
first = false;
}
f.Printf("<TR>");
- f.Printf("<TD valign=top height=22 nowrap=1><img valign=center src=\"%s\"> <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a></TD>", (cl.type == enumClass || cl.type == unitClass || cl.type == systemClass) ? iconNames[typeDataType] : iconNames[typeClass], cl, cl.name);
+ f.Printf("<TD valign=top height=22 nowrap=1><img valign=center src=\"%s\"> <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a></TD>", (cl.type == enumClass || cl.type == unitClass || cl.type == systemClass) ? iconNames[typeDataType] : iconNames[typeClass], cl, cl.name);
if(desc)
{
if(editing)
if(name) name += 2; else name = function.name;
if(first)
{
- f.Printf("<a name=Functions></a><H3>Functions</H3><br><br>\n");
+ f.Printf($"<a name=Functions></a><H3>Functions</H3><br><br>\n");
f.Printf("<TABLE >\n");
first = false;
}
f.Printf("<TR>");
- f.Printf("<TD valign=top height=22 nowrap=1><img valign=center src=\"%s\"> <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a></TD>", iconNames[typeMethod], function, name);
+ f.Printf("<TD valign=top height=22 nowrap=1><img valign=center src=\"%s\"> <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a></TD>", iconNames[typeMethod], function, name);
if(desc)
{
if(editing)
char * desc = ReadDoc(module, nameSpaceDoc, nameSpace, definition, def);
if(first)
{
- f.Printf("<a name=Definitions></a><H3>Definitions</H3><br><br>\n");
+ f.Printf($"<a name=Definitions></a><H3>Definitions</H3><br><br>\n");
f.Printf("<TABLE >\n");
first = false;
}
f.Printf("<TR>");
- f.Printf("<TD valign=top height=22 nowrap=1><a name=%08x></a><img valign=center src=\"%s\"> %s</TD>", def, iconNames[typeData], def.name);
+ f.Printf("<TD valign=top height=22 nowrap=1><a name=%p></a><img valign=center src=\"%s\"> %s</TD>", def, iconNames[typeData], def.name);
f.Printf("<TD valign=top height=22>%s</TD>", def.value);
if(desc)
{
ns = ns->parent;
}
// Generate Class Page
- f.Printf("<HTML><HEAD><TITLE>API Reference</TITLE></HEAD>\n<BODY><FONT SIZE=\"3\">\n");
+ f.Printf($"<HTML><HEAD><TITLE>API Reference</TITLE></HEAD>\n<BODY><FONT SIZE=\"3\">\n");
f.Printf("<FONT FACE=\"Arial\" SIZE=\"6\">%s</FONT><br><br>\n", name);
- f.Printf("Module: <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a><br>\n", (module && module.name) ? module : null, (!module || !module.name || !strcmp(nsName, "ecere::com")) ? "ecereCOM" : module.name);
+ f.Printf($"Module: <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a><br>\n", (module && module.name) ? module : null, (!module || !module.name || !strcmp(nsName, "ecere::com")) ? "ecereCOM" : module.name);
if(nsName[0])
- f.Printf("Namespace: <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a><br>\n", cl.nameSpace, nsName);
+ f.Printf($"Namespace: <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a><br>\n", cl.nameSpace, nsName);
{
char * classType = null;
switch(cl.type)
{
case bitClass:
- classType = "Bit Collection";
+ classType = $"Bit Collection";
break;
case enumClass:
- classType = "Enumeration";
+ classType = $"Enumeration";
break;
case structClass:
- classType = "Structure";
+ classType = $"Structure";
break;
case normalClass:
- classType = "Class";
+ classType = $"Class";
break;
case noHeadClass:
- classType = "Class (No header)";
+ classType = $"Class (No header)";
break;
case unitClass:
- classType = "Unit";
+ classType = $"Unit";
break;
case systemClass:
- classType = "Basic Data Type";
+ classType = $"Basic Data Type";
break;
}
- f.Printf("Type: %s<br>\n", classType);
+ f.Printf($"Type: %s<br>\n", classType);
}
if(cl.type != systemClass && cl.base)
{
- f.Printf("Base Class: ");
+ f.Printf($"Base Class: ");
if(!strcmp(cl.base.name, "struct") || !strcmp(cl.base.name, "class"))
{
- f.Printf(cl.type == bitClass ? cl.dataTypeString : "None");
+ f.Printf(cl.type == bitClass ? cl.dataTypeString : $"None");
}
else if(cl.type == enumClass && !strcmp(cl.base.name, "enum"))
f.Printf("%s", cl.dataTypeString);
else
- f.Printf("<a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a>", cl.base, cl.base.name);
+ f.Printf("<a href=\"api://%p\" style=\"text-decoration: none;\">%s</a>", cl.base.templateClass ? cl.base.templateClass : cl.base, cl.base.name);
f.Printf("<br>\n");
}
char * desc = ReadDoc(module, classDoc, cl, description, null);
if(desc)
{
- f.Printf("<br><H3>Description</H3><br><br>\n");
+ f.Printf($"<br><H3>Description</H3><br><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
{
NamedLink item;
- f.Printf("<a name=EnumerationValues></a><H3>Enumeration Values</H3><br><br>\n");
+ f.Printf($"<a name=EnumerationValues></a><H3>Enumeration Values</H3><br><br>\n");
f.Printf("<TABLE >\n");
for(item = enumeration.values.first; item; item = item.next)
bool needClass = true;
Class dataClass;
Class base = cl;
+ char tempString[1024];
+ String s;
while(base.type == enumClass) base = base.base;
if(base.type == systemClass ||
dataClass = base;
f.Printf("<TR>");
- f.Printf("<TD valign=top height=22 nowrap=1><a name=%08x></a><img valign=center src=\"%s\"> %s</TD>", item, iconNames[typeEnumValue], item.name);
+ f.Printf("<TD valign=top height=22 nowrap=1><a name=%p></a><img valign=center src=\"%s\"> %s</TD>", item, iconNames[typeEnumValue], item.name);
if(dataClass.type == systemClass)
{
needClass = false;
- dataClass._vTbl[__ecereVMethodID_class_OnGetString](dataClass, &item.data, string, sizeof(string), &needClass);
+ s = ((char *(*)(void *, void *, char *, void *, bool *))(void *)dataClass._vTbl[__ecereVMethodID_class_OnGetString])(dataClass, &item.data, tempString, null, &needClass);
}
else
- eSystem_FindClass(componentsApp, "class")._vTbl[__ecereVMethodID_class_OnGetString](dataClass, &item.data, string, sizeof(string), &needClass);
+ s = ((char *(*)(void *, void *, char *, void *, bool *))(void *)eSystem_FindClass(componentsApp, "class")._vTbl[__ecereVMethodID_class_OnGetString])(dataClass, &item.data, tempString, null, &needClass);
if(needClass)
- f.Printf("<TD valign=top height=22 nowrap=1>%s { %s }</TD>", dataClass.name, string);
+ f.Printf("<TD valign=top height=22 nowrap=1>%s { %s }</TD>", dataClass.name, s);
else
- f.Printf("<TD valign=top height=22 nowrap=1>%s</TD>", string);
+ f.Printf("<TD valign=top height=22 nowrap=1>%s</TD>", s);
if(desc)
{
if(editing)
if(cl.conversions.first)
{
- f.Printf("<a name=Conversions></a><H3>Conversions</H3><br><br>\n");
+ f.Printf($"<a name=Conversions></a><H3>Conversions</H3><br><br>\n");
f.Printf("<TABLE >\n");
for(prop = cl.conversions.first; prop; prop = prop.next)
{
string[0] = 0;
DocPrintType(type, string, true, false);
- f.Printf("<TD valign=top height=22 nowrap=1><a name=%08x></a><img valign=center src=\"%s\"> %s</TD>", prop, iconNames[typeDataType], string);
+ f.Printf("<TD valign=top height=22 nowrap=1><a name=%p></a><img valign=center src=\"%s\"> %s</TD>", prop, iconNames[typeDataType], string);
if(desc)
{
if(editing)
{
if(first)
{
- f.Printf("<a name=Members></a><H3>Properties and Members</H3><br><br>\n");
+ f.Printf($"<a name=Members></a><H3>Properties and Members</H3><br><br>\n");
f.Printf("<TABLE >\n");
first = false;
}
string[0] = 0;
DocPrintType(prop.dataType, string, true, false);
- f.Printf("<TD valign=top height=22 nowrap=1><a name=%08x></a><img valign=center src=\"%s\"> %s</TD>", prop, iconNames[typeProperty], prop.name);
+ f.Printf("<TD valign=top height=22 nowrap=1><a name=%p></a><img valign=center src=\"%s\"> %s</TD>", prop, iconNames[typeProperty], prop.name);
f.Printf("<TD valign=top height=22 nowrap=1>%s</TD>", string);
if(desc)
{
char * desc = ReadDoc(module, methodDoc, method, description, null);
if(first)
{
- f.Printf("<a name=VirtualMethods></a><H3>Virtual Methods</H3><br><br>\n");
+ f.Printf($"<a name=VirtualMethods></a><H3>Virtual Methods</H3><br><br>\n");
f.Printf("<TABLE >\n");
first = false;
}
ProcessMethodType(method);
f.Printf("<TR>");
- f.Printf("<TD valign=top height=22 nowrap=1><img valign=center src=\"%s\"> <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a></TD>", method.dataType.thisClass ? iconNames[typeEvent] : iconNames[typeMethod], method, method.name);
+ f.Printf("<TD valign=top height=22 nowrap=1><img valign=center src=\"%s\"> <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a></TD>", method.dataType.thisClass ? iconNames[typeEvent] : iconNames[typeMethod], method, method.name);
if(desc)
{
if(editing)
char * desc = ReadDoc(module, methodDoc, method, description, null);
if(first)
{
- f.Printf("<a name=Methods></a><H3>Non-Virtual Methods</H3><br><br>\n");
+ f.Printf($"<a name=Methods></a><H3>Non-Virtual Methods</H3><br><br>\n");
f.Printf("<TABLE >\n");
first = false;
}
ProcessMethodType(method);
f.Printf("<TR>");
- f.Printf("<TD valign=top height=22 nowrap=1><img valign=center src=\"%s\"> <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a></TD>", iconNames[typeMethod], method, method.name);
+ f.Printf("<TD valign=top height=22 nowrap=1><img valign=center src=\"%s\"> <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a></TD>", iconNames[typeMethod], method, method.name);
if(desc)
{
if(editing)
char * usageDoc = ReadDoc(module, classDoc, cl, usage, null);
if(usageDoc)
{
- f.Printf("<H3>Usage</H3><br>\n");
+ f.Printf($"<H3>Usage</H3><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
char * exampleDoc = ReadDoc(module, classDoc, cl, example, null);
if(exampleDoc)
{
- f.Printf("<H3>Example</H3><br>\n");
- f.Printf("<FONT face=\"Courier New\">\n");
+ f.Printf($"<H3>Example</H3><br>\n");
+ f.Printf($"<FONT face=\"Courier New\">\n");
f.Printf("<br><TABLE >\n");
if(editing)
{
if(remarksDoc)
{
- f.Printf("<H3>Remarks</H3><br>\n");
+ f.Printf($"<H3>Remarks</H3><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
{
if(first)
{
- f.Printf("<H3>Derived Classes</H3><br>\n");
+ f.Printf($"<H3>Derived Classes</H3><br>\n");
f.Printf("<br>");
first = false;
}
else
f.Printf(", ");
- f.Printf("<a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a>", deriv, deriv.name);
+ f.Printf("<a href=\"api://%p\" style=\"text-decoration: none;\">%s</a>", deriv, deriv.name);
}
}
if(!first)
char * seeAlsoDoc = ReadDoc(module, classDoc, cl, seeAlso, null);
if(seeAlsoDoc)
{
- f.Printf("<H3>See Also</H3><br>\n");
+ f.Printf($"<H3>See Also</H3><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
ns = ns->parent;
}
- f.Printf("<HTML><HEAD><TITLE>API Reference</TITLE></HEAD>\n<BODY><FONT SIZE=\"3\">\n");
+ f.Printf($"<HTML><HEAD><TITLE>API Reference</TITLE></HEAD>\n<BODY><FONT SIZE=\"3\">\n");
f.Printf("<FONT FACE=\"Arial\" SIZE=\"6\">%s</FONT><br><br>\n", name);
- f.Printf("Module: <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a><br>\n", (module && module.name) ? module : null, (!module || !module.name || !strcmp(nsName, "ecere::com")) ? "ecereCOM" : module.name);
+ f.Printf($"Module: <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a><br>\n", (module && module.name) ? module : null, (!module || !module.name || !strcmp(nsName, "ecere::com")) ? "ecereCOM" : module.name);
if(nsName[0])
- f.Printf("Namespace: <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a><br>\n", cl.nameSpace, nsName);
- f.Printf("Class: <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a><br>\n", cl, cl.name);
+ f.Printf($"Namespace: <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a><br>\n", cl.nameSpace, nsName);
+ f.Printf("Class: <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a><br>\n", cl, cl.name);
if(method.dataType.staticMethod)
{
- f.Printf("this pointer class: None<br>\n");
+ f.Printf($"this pointer class: None<br>\n");
}
else if(method.dataType.thisClass && method.dataType.thisClass.registered && (method.dataType.thisClass.registered != method._class || method.type == virtualMethod))
{
- f.Printf("this pointer class: <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a><br>\n", method.dataType.thisClass.registered, method.dataType.thisClass.registered.name);
+ f.Printf($"this pointer class: <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a><br>\n", method.dataType.thisClass.registered, method.dataType.thisClass.registered.name);
}
// Generate Method Page
char * desc = ReadDoc(module, methodDoc, method, description, null);
if(desc)
{
- f.Printf("<br><br><H3>Description</H3><br><br>\n");
+ f.Printf($"<br><br><H3>Description</H3><br><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
f.Printf("<br><br>\n");
if(method.dataType.params.first && ((Type)method.dataType.params.first).kind != voidType)
{
- f.Printf("<H3>Parameters</H3><br><br>\n");
+ f.Printf($"<H3>Parameters</H3><br><br>\n");
}
if((method.dataType.returnType && method.dataType.returnType.kind != voidType) ||
(method.dataType.params.first && ((Type)method.dataType.params.first).kind != voidType))
f.Printf("<TR><TD> </TD></TR>");
}
f.Printf("<TR>");
- f.Printf("<TD valign=top height=22 nowrap=1><B>Return Value</B></TD>\n");
+ f.Printf($"<TD valign=top height=22 nowrap=1><B>Return Value</B></TD>\n");
string[0] = 0;
DocPrintType(method.dataType.returnType, string, false, false);
f.Printf("<TD valign=top height=22>%s </TD>\n", string);
char * usageDoc = ReadDoc(module, methodDoc, method, usage, null);
if(usageDoc)
{
- f.Printf("<H3>Usage</H3><br>\n");
+ f.Printf($"<H3>Usage</H3><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
char * exampleDoc = ReadDoc(module, methodDoc, method, example, null);
if(exampleDoc)
{
- f.Printf("<H3>Example</H3><br>\n");
- f.Printf("<FONT face=\"Courier New\">\n");
+ f.Printf($"<H3>Example</H3><br>\n");
+ f.Printf($"<FONT face=\"Courier New\">\n");
f.Printf("<br><TABLE >\n");
if(editing)
{
char * remarksDoc = ReadDoc(module, methodDoc, method, remarks, null);
if(remarksDoc)
{
- f.Printf("<H3>Remarks</H3><br>\n");
+ f.Printf($"<H3>Remarks</H3><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
char * seeAlsoDoc = ReadDoc(module, methodDoc, method, seeAlso, null);
if(seeAlsoDoc)
{
- f.Printf("<H3>See Also</H3><br>\n");
+ f.Printf($"<H3>See Also</H3><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
ns = ns->parent;
}
- f.Printf("<HTML><HEAD><TITLE>API Reference</TITLE></HEAD>\n<BODY><FONT SIZE=\"3\">\n");
+ f.Printf($"<HTML><HEAD><TITLE>API Reference</TITLE></HEAD>\n<BODY><FONT SIZE=\"3\">\n");
f.Printf("<FONT FACE=\"Arial\" SIZE=\"6\">%s</FONT><br><br>\n", name);
- f.Printf("Module: <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a><br>\n", (module && module.name) ? module : null, (!module || !module.name || !strcmp(nsName, "ecere::com")) ? "ecereCOM" : module.name);
+ f.Printf($"Module: <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a><br>\n", (module && module.name) ? module : null, (!module || !module.name || !strcmp(nsName, "ecere::com")) ? "ecereCOM" : module.name);
+
if(nsName[0])
- f.Printf("Namespace: <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a><br>\n", function.nameSpace, nsName);
+ f.Printf($"Namespace: <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a><br>\n", function.nameSpace, nsName);
if(!function.dataType)
function.dataType = ProcessTypeString(function.dataTypeString, false);
if(function.dataType.thisClass && function.dataType.thisClass.registered)
{
- f.Printf("this pointer class: <a href=\"api://%08x\" style=\"text-decoration: none;\">%s</a><br>\n", function.dataType.thisClass.registered, function.dataType.thisClass.registered.name);
+ f.Printf($"this pointer class: <a href=\"api://%p\" style=\"text-decoration: none;\">%s</a><br>\n", function.dataType.thisClass.registered, function.dataType.thisClass.registered.name);
}
// Generate Method Page
char * desc = ReadDoc(module, functionDoc, function, description, null);
if(desc)
{
- f.Printf("<br><br><H3>Description</H3><br><br>\n");
+ f.Printf($"<br><br><H3>Description</H3><br><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
f.Printf("<br><br>\n");
if(function.dataType.params.first && ((Type)function.dataType.params.first).kind != voidType)
{
- f.Printf("<H3>Parameters</H3><br><br>\n");
+ f.Printf($"<H3>Parameters</H3><br><br>\n");
}
if((function.dataType.returnType && function.dataType.returnType.kind != voidType) ||
(function.dataType.params.first && ((Type)function.dataType.params.first).kind != voidType))
f.Printf("<TR><TD> </TD></TR>");
}
f.Printf("<TR>");
- f.Printf("<TD valign=top height=22 nowrap=1><B>Return Value</B></TD>\n");
+ f.Printf($"<TD valign=top height=22 nowrap=1><B>Return Value</B></TD>\n");
string[0] = 0;
DocPrintType(function.dataType.returnType, string, false, false);
f.Printf("<TD valign=top height=22>%s </TD>\n", string);
char * usageDoc = ReadDoc(module, functionDoc, function, usage, null);
if(usageDoc)
{
- f.Printf("<H3>Usage</H3><br>\n");
+ f.Printf($"<H3>Usage</H3><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
char * exampleDoc = ReadDoc(module, functionDoc, function, example, null);
if(exampleDoc)
{
- f.Printf("<H3>Example</H3><br>\n");
- f.Printf("<FONT face=\"Courier New\">\n");
+ f.Printf($"<H3>Example</H3><br>\n");
+ f.Printf($"<FONT face=\"Courier New\">\n");
f.Printf("<br><TABLE >\n");
if(editing)
{
char * remarksDoc = ReadDoc(module, functionDoc, function, remarks, null);
if(remarksDoc)
{
- f.Printf("<H3>Remarks</H3><br>\n");
+ f.Printf($"<H3>Remarks</H3><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
char * seeAlsoDoc = ReadDoc(module, functionDoc, function, seeAlso, null);
if(seeAlsoDoc)
{
- f.Printf("<H3>See Also</H3><br>\n");
+ f.Printf($"<H3>See Also</H3><br>\n");
if(editing)
{
char fileName[MAX_LOCATION];
cl = link.data;
if(!cl.templateClass && (!module || cl.module == module || (!cl.module.name && !strcmp(module.name, "ecere"))))
{
- if(!classesRow) { classesRow = row.AddRow(); classesRow.SetData(null, APIPage { "Classes", page = page }); classesRow.collapsed = true; classesRow.icon = mainForm.icons[typeClass]; classesRow.tag = 1; }
+ if(!classesRow) { classesRow = row.AddRow(); classesRow.SetData(null, APIPage { $"Classes", page = page }); classesRow.collapsed = true; classesRow.icon = mainForm.icons[typeClass]; classesRow.tag = 1; }
AddClass(classesRow, module, cl, nsName, showPrivate);
}
}
{
char * name = ( name = RSearchString(fn.name, "::", strlen(fn.name), false, false), name ? name + 2 : fn.name);
DataRow fnRow;
- if(!functionsRow) { functionsRow = row.AddRow(); functionsRow.SetData(null, APIPage { "Functions", page = page }); functionsRow.collapsed = true; functionsRow.icon = mainForm.icons[typeMethod]; functionsRow.tag = 2; };
+ if(!functionsRow) { functionsRow = row.AddRow(); functionsRow.SetData(null, APIPage { $"Functions", page = page }); functionsRow.collapsed = true; functionsRow.icon = mainForm.icons[typeMethod]; functionsRow.tag = 2; };
fnRow = functionsRow.AddRow(); fnRow.SetData(null, APIPageFunction { name, function = fn }); fnRow.icon = mainForm.icons[typeMethod]; fnRow.tag = (int)fn;
}
}
{
char * name = ( name = RSearchString(def.name, "::", strlen(def.name), false, false), name ? name + 2 : def.name);
DataRow defRow;
- if(!definesRow) { definesRow = row.AddRow(); definesRow.SetData(null, APIPage { "Definitions", page = page }); definesRow.collapsed = true; definesRow.icon = mainForm.icons[typeData]; definesRow.tag = 3; };
+ if(!definesRow) { definesRow = row.AddRow(); definesRow.SetData(null, APIPage { $"Definitions", page = page }); definesRow.collapsed = true; definesRow.icon = mainForm.icons[typeData]; definesRow.tag = 3; };
defRow = definesRow.AddRow(); defRow.SetData(null, APIPage { name, page = page }); defRow.icon = mainForm.icons[typeData]; defRow.tag = (int)def;
}
}
string[0] = 0;
DocPrintType(member.dataType, string, true, false);
- f.Printf("<TD valign=top height=22 nowrap=1><a name=%08x></a>", member);
+ f.Printf("<TD valign=top height=22 nowrap=1><a name=%p></a>", member);
for(c = 0; c<indent; c++)
f.Printf(" ");
f.Printf("<img valign=center src=\"%s\"> %s</TD>", iconNames[typeData], member.name ? member.name : ((member.type == structMember) ? "(struct)" : "(union)"));
{
if(method.dataType.thisClass)
{
- if(!eventsRow) { eventsRow = row.AddRow(); eventsRow.SetData(null, APIPage { "Events", page = page }); eventsRow.collapsed = true; eventsRow.icon = mainForm.icons[typeEvent]; eventsRow.tag = 4; }
+ if(!eventsRow) { eventsRow = row.AddRow(); eventsRow.SetData(null, APIPage { $"Events", page = page }); eventsRow.collapsed = true; eventsRow.icon = mainForm.icons[typeEvent]; eventsRow.tag = 4; }
mRow = eventsRow.AddRow(); mRow.SetData(null, APIPageMethod { method.name, method = method }); mRow.icon = mainForm.icons[typeEvent];
mRow.tag = (int)method;
}
else
{
- if(!virtualsRow) { virtualsRow = row.AddRow(); virtualsRow.SetData(null, APIPage { "Virtual Methods", page = page }); virtualsRow.collapsed = true; virtualsRow.icon = mainForm.icons[typeMethod]; virtualsRow.tag = 4; }
+ if(!virtualsRow) { virtualsRow = row.AddRow(); virtualsRow.SetData(null, APIPage { $"Virtual Methods", page = page }); virtualsRow.collapsed = true; virtualsRow.icon = mainForm.icons[typeMethod]; virtualsRow.tag = 4; }
mRow = virtualsRow.AddRow(); mRow.SetData(null, APIPageMethod { method.name, method = method }); mRow.icon = mainForm.icons[typeMethod];
mRow.tag = (int)method;
}
}
else
{
- if(!methodsRow) { methodsRow = row.AddRow(); methodsRow.SetData(null, APIPage { "Methods", page = page }); methodsRow.collapsed = true; methodsRow.icon = mainForm.icons[typeMethod]; methodsRow.tag = 5; }
+ if(!methodsRow) { methodsRow = row.AddRow(); methodsRow.SetData(null, APIPage { $"Methods", page = page }); methodsRow.collapsed = true; methodsRow.icon = mainForm.icons[typeMethod]; methodsRow.tag = 5; }
mRow = methodsRow.AddRow(); mRow.SetData(null, APIPageMethod { method.name, method = method }); mRow.icon = mainForm.icons[typeMethod];
mRow.tag = (int)method;
}
if(prop.isProperty)
{
DataRow mRow;
- if(!propertiesRow) { propertiesRow = row.AddRow(); propertiesRow.SetData(null, APIPage { "Properties", page = page }); propertiesRow.collapsed = true; propertiesRow.icon = mainForm.icons[typeProperty]; propertiesRow.tag = 6; }
+ if(!propertiesRow) { propertiesRow = row.AddRow(); propertiesRow.SetData(null, APIPage { $"Properties", page = page }); propertiesRow.collapsed = true; propertiesRow.icon = mainForm.icons[typeProperty]; propertiesRow.tag = 6; }
mRow = propertiesRow.AddRow(); mRow.SetData(null, APIPage { prop.name, page }); mRow.icon = mainForm.icons[typeProperty];
mRow.tag = (int)prop;
}
else
{
- if(!membersRow) { membersRow = row.AddRow(); membersRow.SetData(null, APIPage { "Data Members", page = page }); membersRow.collapsed = true; membersRow.icon = mainForm.icons[typeData]; membersRow.tag = 6; }
+ if(!membersRow) { membersRow = row.AddRow(); membersRow.SetData(null, APIPage { $"Data Members", page = page }); membersRow.collapsed = true; membersRow.icon = mainForm.icons[typeData]; membersRow.tag = 6; }
AddDataMember(membersRow, page, (DataMember)prop);
}
}
{
DataRow mRow;
char * name;
- if(!conversionsRow) { conversionsRow = row.AddRow(); conversionsRow.SetData(null, APIPage { "Conversions", page = page }); conversionsRow.collapsed = true; conversionsRow.icon = mainForm.icons[typeDataType]; conversionsRow.tag = 7; }
+ if(!conversionsRow) { conversionsRow = row.AddRow(); conversionsRow.SetData(null, APIPage { $"Conversions", page = page }); conversionsRow.collapsed = true; conversionsRow.icon = mainForm.icons[typeDataType]; conversionsRow.tag = 7; }
name = RSearchString(prop.name, "::", strlen(prop.name), true, false);
if(name) name += 2; else name = prop.name;
mRow = conversionsRow.AddRow(); mRow.SetData(null, APIPage { name, page = page }); mRow.icon = mainForm.icons[typeDataType];
for(item = enumeration.values.first; item; item = item.next)
{
DataRow mRow;
- if(!enumRow) { enumRow = row.AddRow(); enumRow.SetData(null, APIPage { "Enumeration Values", page = page }); enumRow.collapsed = true; enumRow.icon = mainForm.icons[typeEnumValue]; enumRow.tag = 8; }
+ if(!enumRow) { enumRow = row.AddRow(); enumRow.SetData(null, APIPage { $"Enumeration Values", page = page }); enumRow.collapsed = true; enumRow.icon = mainForm.icons[typeEnumValue]; enumRow.tag = 8; }
mRow = enumRow.AddRow(); mRow.SetData(null, APIPage { item.name, page = page }); mRow.icon = mainForm.icons[typeEnumValue];
mRow.tag = (int)item;
}
borderStyle = sizable;
hasMaximize = true;
hasMinimize = true;
- text = "API Documentation Browser";
-
nativeDecorations = true;
+ icon = { ":documentorIcon.png" };
+ text = $"API Documentation Browser";
BitmapResource icons[CodeObjectType];
hasMenuBar = true;
menu = Menu { };
- Menu fileMenu { menu, "File", f };
+ Menu fileMenu { menu, $"File", f };
+ Array<FileFilter> fileFilters
+ { [
+ { $"eC Shared Library files (*.dll, *.so, *.dylib)", "dll, so, dylib" },
+ { $"eC Symbol files (*.sym)", "sym" }
+ ] };
+
FileDialog fileDialog
{
- filters = fileFilters, sizeFilters = sizeof(fileFilters)
+ filters = fileFilters.array, sizeFilters = fileFilters.count * sizeof(FileFilter)
};
MenuItem fileOpenItem
{
- fileMenu, "Open...", o, ctrlO;
+ fileMenu, $"Open...", o, ctrlO;
bool NotifySelect(MenuItem selection, Modifiers mods)
{
};
MenuItem fileSettingsItem
{
- fileMenu, "Settings...", s, ctrlS; // set the Settings item to the file menu with shortcut keys:s and ctrl+s
+ fileMenu, $"Settings...", s, ctrlS; // set the Settings item to the file menu with shortcut keys:s and ctrl+s
bool NotifySelect(MenuItem selection, Modifiers mods)
{
SettingsDialog { master = this }.Modal(); // Open the settings dialog to allow the user to change the directory for the eCdoc files
+ return true;
}
};
MenuDivider { fileMenu };
- MenuItem fileExit { fileMenu, "Exit", x, altF4, NotifySelect = MenuFileExit };
+ MenuItem fileExit { fileMenu, $"Exit", x, altF4, NotifySelect = MenuFileExit };
void OpenModule(char * filePath)
{
case 8: view.GoToAnchor("EnumerationValues"); break;
default:
{
- char hex[10];
- sprintf(hex, "%08x", row.tag);
+ char hex[20];
+ sprintf(hex, "%p", row.tag);
view.GoToAnchor(hex);
}
}
};
Button saveChanges
{
- this, text = "Save Changes", anchor = { horz = 184, vert = 160 }
+ this, text = $"Save Changes", anchor = { horz = 184, vert = 160 }
};
Button cancel
{
- this, text = "Cancel", anchor = { horz = 254, vert = 160 }
+ this, text = $"Cancel", anchor = { horz = 254, vert = 160 }
};
}
delete block;
}
textBlock = Block { type = TEXT, parent = parent, font = parent.font };
- textBlock.text = CopyString("[Add Text]");
+ textBlock.text = CopyString($"[Add Text]");
textBlock.textLen = strlen(textBlock.text);
parent.subBlocks.Add(textBlock);
}
{
if(!strncmp(href, "api://", 6))
{
- int tag = strtoul(href + 6, null, 16);
+ int tag = (uint)strtoul(href + 6, null, 16);
DataRow row = mainForm.browser.FindSubRow(tag);
if(row)
{
}
textBlock = (Block)clickedLink.subBlocks.first;
- if(!strcmp(textBlock.text, "[Add Text]"))
+ if(!strcmp(textBlock.text, $"[Add Text]"))
{
textBlock.text[0] = 0;
textBlock.textLen = 0;
default:
{
// eC BUG HERE: (Should be fixed)
- if(key.ctrl && !key.alt && ch >= 32 && ch != 128 /*&& ch < 128*/)
+ if(!key.ctrl && !key.alt && ch >= 32 && ch != 128 /*&& ch < 128*/)
{
char string[5];
int len = UTF32toUTF8Len(&ch, 1, string, 5);