code clean up, code review, styling tweaks

This commit is contained in:
camh 2021-11-28 23:25:07 -08:00
parent 9d338480c0
commit 5d9ffc1b6f
12 changed files with 493 additions and 611 deletions

View File

@ -76,15 +76,8 @@ void AlertUser( void );
#define TopLeft(aRect) (* (Point *) &(aRect).top)
#define BotRight(aRect) (* (Point *) &(aRect).bottom)
// TODO:
// - IN PROGRESS new message window -- needs to blank out messages, then needs fixes on new mac end
// - chat during the day for a few minutes and figure out small issues
// - start writing blog posts
// - get new messages in other chats and display some sort of alert
// - need timeout on serial messages in case the computer at the other end dies (prevent hard reset)
// - delete doesnt work right (leaves characters at end of string)
// - move app-specific code to distinct file
// this function, EventLoop, and DoEvent contain all of the business logic necessary
// for our application to run
#pragma segment Main
void main()
{
@ -108,7 +101,6 @@ void main()
EventLoop(ctx); /* call the main event loop */
}
#pragma segment Main
void EventLoop(struct nk_context *ctx)
{
@ -143,16 +135,6 @@ void EventLoop(struct nk_context *ctx)
Boolean beganInput = false;
#ifdef MAC_APP_DEBUGGING
writeSerialPortDebug(boutRefNum, "nk_input_begin");
#endif
#ifdef MAC_APP_DEBUGGING
writeSerialPortDebug(boutRefNum, "nk_input_begin complete");
#endif
GetGlobalMouse(&mouse);
// as far as i can tell, there is no way to event on mouse movement with mac libraries,
@ -164,16 +146,16 @@ void EventLoop(struct nk_context *ctx)
#ifdef MAC_APP_DEBUGGING
// writeSerialPortDebug(boutRefNum, "nk_input_motion!");
writeSerialPortDebug(boutRefNum, "nk_input_motion!");
#endif
firstOrMouseMove = true;
beganInput = true;
Point tempPoint;
SetPt(&tempPoint, mouse.h, mouse.v);
GlobalToLocal(&tempPoint);
beganInput = true;
nk_input_begin(ctx);
nk_input_motion(ctx, tempPoint.h, tempPoint.v);
@ -224,7 +206,7 @@ void EventLoop(struct nk_context *ctx)
SystemTask();
// only re-render if there is an event, prevents screen flickering
// only re-render if there is an event, prevents screen flickering, speeds up app
if (beganInput || firstOrMouseMove) {
nk_input_end(ctx);
@ -243,10 +225,9 @@ void EventLoop(struct nk_context *ctx)
nk_clear(ctx);
}
#ifdef MAC_APP_DEBUGGING
// writeSerialPortDebug(boutRefNum, "nk_input_render complete");
writeSerialPortDebug(boutRefNum, "nk_input_render complete");
#endif
} while ( true ); /* loop forever; we quit via ExitToShell */
} /*EventLoop*/
@ -272,7 +253,7 @@ void DoEvent(EventRecord *event, struct nk_context *ctx) {
gotMouseEvent = true;
#ifdef MAC_APP_DEBUGGING
// writeSerialPortDebug(boutRefNum, "mouseup");
writeSerialPortDebug(boutRefNum, "mouseup");
#endif
part = FindWindow(event->where, &window);
@ -306,7 +287,6 @@ void DoEvent(EventRecord *event, struct nk_context *ctx) {
case inContent:
if ( window != FrontWindow() ) {
SelectWindow(window);
}
nk_quickdraw_handle_event(event, ctx);
break;
@ -330,7 +310,6 @@ void DoEvent(EventRecord *event, struct nk_context *ctx) {
case keyDown:
case autoKey: /* check for menukey equivalents */
#ifdef MAC_APP_DEBUGGING
writeSerialPortDebug(boutRefNum, "key");
#endif
@ -485,7 +464,7 @@ void AdjustMenus()
EnableItem(menu, iCopy);
EnableItem(menu, iClear);
EnableItem(menu, iPaste);
} else { /* Ébut we donÕt use it */
} else { /* but we dont use it */
DisableItem(menu, iUndo);
DisableItem(menu, iCut);
DisableItem(menu, iCopy);
@ -553,6 +532,8 @@ void DoMenuCommand(menuResult)
handledByDA = SystemEdit(menuItem-1); /* since we donÕt do any Editing */
break;
case mLight:
// note this was co-opted to send new chats instead of the demo functionality. do the
// same thing for other menu items as necessary
sendNewChat = 1;
break;

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 325 KiB

After

Width:  |  Height:  |  Size: 324 KiB

View File

@ -33,13 +33,13 @@ The CXX compiler identification is GNU, found in "/home/camh/Documents/Retro68kA
Determining if the C compiler works passed with the following output:
Change Dir: /home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp
Run Build Command(s):/usr/bin/make cmTC_918b7/fast && /usr/bin/make -f CMakeFiles/cmTC_918b7.dir/build.make CMakeFiles/cmTC_918b7.dir/build
Run Build Command(s):/usr/bin/make cmTC_1cb57/fast && /usr/bin/make -f CMakeFiles/cmTC_1cb57.dir/build.make CMakeFiles/cmTC_1cb57.dir/build
make[1]: Entering directory '/home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_918b7.dir/testCCompiler.c.obj
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc -o CMakeFiles/cmTC_918b7.dir/testCCompiler.c.obj -c /home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp/testCCompiler.c
Linking C executable cmTC_918b7
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_918b7.dir/link.txt --verbose=1
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc CMakeFiles/cmTC_918b7.dir/testCCompiler.c.obj -o cmTC_918b7
Building C object CMakeFiles/cmTC_1cb57.dir/testCCompiler.c.obj
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc -o CMakeFiles/cmTC_1cb57.dir/testCCompiler.c.obj -c /home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp/testCCompiler.c
Linking C executable cmTC_1cb57
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_1cb57.dir/link.txt --verbose=1
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc CMakeFiles/cmTC_1cb57.dir/testCCompiler.c.obj -o cmTC_1cb57
make[1]: Leaving directory '/home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp'
@ -47,18 +47,18 @@ make[1]: Leaving directory '/home/camh/Documents/Retro68kApps/NuklearQuickDraw/b
Detecting C compiler ABI info compiled with the following output:
Change Dir: /home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp
Run Build Command(s):/usr/bin/make cmTC_e11fa/fast && /usr/bin/make -f CMakeFiles/cmTC_e11fa.dir/build.make CMakeFiles/cmTC_e11fa.dir/build
Run Build Command(s):/usr/bin/make cmTC_46844/fast && /usr/bin/make -f CMakeFiles/cmTC_46844.dir/build.make CMakeFiles/cmTC_46844.dir/build
make[1]: Entering directory '/home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc -v -o CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj -c /usr/share/cmake-3.16/Modules/CMakeCCompilerABI.c
Building C object CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc -v -o CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj -c /usr/share/cmake-3.16/Modules/CMakeCCompilerABI.c
Using built-in specs.
COLLECT_GCC=/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc
Target: m68k-apple-macos
Configured with: /home/camh/Retro68/gcc/configure --target=m68k-apple-macos --prefix=/home/camh/Retro68-build/toolchain/ --enable-languages=c,c++ --with-arch=m68k --with-cpu=m68000 --disable-libssp MAKEINFO=missing
Thread model: single
gcc version 9.1.0 (GCC)
COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj' '-c' '-mcpu=68000'
/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/cc1 -quiet -v -Wno-trigraphs /usr/share/cmake-3.16/Modules/CMakeCCompilerABI.c -quiet -dumpbase CMakeCCompilerABI.c -mcpu=68000 -auxbase-strip CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj -version -o /tmp/ccSTTGFz.s
COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj' '-c' '-mcpu=68000'
/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/cc1 -quiet -v -Wno-trigraphs /usr/share/cmake-3.16/Modules/CMakeCCompilerABI.c -quiet -dumpbase CMakeCCompilerABI.c -mcpu=68000 -auxbase-strip CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj -version -o /tmp/ccpERgLV.s
GNU C17 (GCC) version 9.1.0 (m68k-apple-macos)
compiled by GNU C version 9.3.0, GMP version 6.2.0, MPFR version 4.0.2, MPC version 1.1.0, isl version none
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
@ -73,14 +73,14 @@ GNU C17 (GCC) version 9.1.0 (m68k-apple-macos)
compiled by GNU C version 9.3.0, GMP version 6.2.0, MPFR version 4.0.2, MPC version 1.1.0, isl version none
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: 68baab70957df643ffb4605a09112146
COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj' '-c' '-mcpu=68000'
/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/as -mcpu=68000 -o CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj /tmp/ccSTTGFz.s
COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj' '-c' '-mcpu=68000'
/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/as -mcpu=68000 -o CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj /tmp/ccpERgLV.s
COMPILER_PATH=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/
LIBRARY_PATH=/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib/
COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj' '-c' '-mcpu=68000'
Linking C executable cmTC_e11fa
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_e11fa.dir/link.txt --verbose=1
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc -v CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj -o cmTC_e11fa
COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj' '-c' '-mcpu=68000'
Linking C executable cmTC_46844
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_46844.dir/link.txt --verbose=1
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc -v CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj -o cmTC_46844
Using built-in specs.
COLLECT_GCC=/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc
COLLECT_LTO_WRAPPER=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper
@ -90,9 +90,9 @@ Thread model: single
gcc version 9.1.0 (GCC)
COMPILER_PATH=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/
LIBRARY_PATH=/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib/
COLLECT_GCC_OPTIONS='-v' '-o' 'cmTC_e11fa' '-mcpu=68000'
/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/collect2 -plugin /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/liblto_plugin.so -plugin-opt=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper -plugin-opt=-fresolution=/tmp/cc8x2spZ.res -plugin-opt=-pass-through=-lgcc -plugin-opt=-pass-through=-lc -plugin-opt=-pass-through=-lretrocrt -plugin-opt=-pass-through=-lInterface -elf2mac -q -undefined=_consolewrite -o cmTC_e11fa -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0 -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj --start-group -lgcc -lc -lretrocrt -lInterface --end-group
COLLECT_GCC_OPTIONS='-v' '-o' 'cmTC_e11fa' '-mcpu=68000'
COLLECT_GCC_OPTIONS='-v' '-o' 'cmTC_46844' '-mcpu=68000'
/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/collect2 -plugin /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/liblto_plugin.so -plugin-opt=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper -plugin-opt=-fresolution=/tmp/ccExJbHq.res -plugin-opt=-pass-through=-lgcc -plugin-opt=-pass-through=-lc -plugin-opt=-pass-through=-lretrocrt -plugin-opt=-pass-through=-lInterface -elf2mac -q -undefined=_consolewrite -o cmTC_46844 -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0 -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj --start-group -lgcc -lc -lretrocrt -lInterface --end-group
COLLECT_GCC_OPTIONS='-v' '-o' 'cmTC_46844' '-mcpu=68000'
make[1]: Leaving directory '/home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp'
@ -114,18 +114,18 @@ Parsed C implicit link information from above output:
link line regex: [^( *|.*[/\])(m68k-apple-macos-ld|CMAKE_LINK_STARTFILE-NOTFOUND|([^/\]+-)?ld|collect2)[^/\]*( |$)]
ignore line: [Change Dir: /home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp]
ignore line: []
ignore line: [Run Build Command(s):/usr/bin/make cmTC_e11fa/fast && /usr/bin/make -f CMakeFiles/cmTC_e11fa.dir/build.make CMakeFiles/cmTC_e11fa.dir/build]
ignore line: [Run Build Command(s):/usr/bin/make cmTC_46844/fast && /usr/bin/make -f CMakeFiles/cmTC_46844.dir/build.make CMakeFiles/cmTC_46844.dir/build]
ignore line: [make[1]: Entering directory '/home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp']
ignore line: [Building C object CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj]
ignore line: [/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc -v -o CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj -c /usr/share/cmake-3.16/Modules/CMakeCCompilerABI.c]
ignore line: [Building C object CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj]
ignore line: [/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc -v -o CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj -c /usr/share/cmake-3.16/Modules/CMakeCCompilerABI.c]
ignore line: [Using built-in specs.]
ignore line: [COLLECT_GCC=/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc]
ignore line: [Target: m68k-apple-macos]
ignore line: [Configured with: /home/camh/Retro68/gcc/configure --target=m68k-apple-macos --prefix=/home/camh/Retro68-build/toolchain/ --enable-languages=c c++ --with-arch=m68k --with-cpu=m68000 --disable-libssp MAKEINFO=missing]
ignore line: [Thread model: single]
ignore line: [gcc version 9.1.0 (GCC) ]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj' '-c' '-mcpu=68000']
ignore line: [ /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/cc1 -quiet -v -Wno-trigraphs /usr/share/cmake-3.16/Modules/CMakeCCompilerABI.c -quiet -dumpbase CMakeCCompilerABI.c -mcpu=68000 -auxbase-strip CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj -version -o /tmp/ccSTTGFz.s]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj' '-c' '-mcpu=68000']
ignore line: [ /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/cc1 -quiet -v -Wno-trigraphs /usr/share/cmake-3.16/Modules/CMakeCCompilerABI.c -quiet -dumpbase CMakeCCompilerABI.c -mcpu=68000 -auxbase-strip CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj -version -o /tmp/ccpERgLV.s]
ignore line: [GNU C17 (GCC) version 9.1.0 (m68k-apple-macos)]
ignore line: [ compiled by GNU C version 9.3.0 GMP version 6.2.0 MPFR version 4.0.2 MPC version 1.1.0 isl version none]
ignore line: [GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072]
@ -140,14 +140,14 @@ Parsed C implicit link information from above output:
ignore line: [ compiled by GNU C version 9.3.0 GMP version 6.2.0 MPFR version 4.0.2 MPC version 1.1.0 isl version none]
ignore line: [GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072]
ignore line: [Compiler executable checksum: 68baab70957df643ffb4605a09112146]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj' '-c' '-mcpu=68000']
ignore line: [ /home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/as -mcpu=68000 -o CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj /tmp/ccSTTGFz.s]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj' '-c' '-mcpu=68000']
ignore line: [ /home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/as -mcpu=68000 -o CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj /tmp/ccpERgLV.s]
ignore line: [COMPILER_PATH=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/]
ignore line: [LIBRARY_PATH=/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib/]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj' '-c' '-mcpu=68000']
ignore line: [Linking C executable cmTC_e11fa]
ignore line: [/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_e11fa.dir/link.txt --verbose=1]
ignore line: [/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc -v CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj -o cmTC_e11fa ]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj' '-c' '-mcpu=68000']
ignore line: [Linking C executable cmTC_46844]
ignore line: [/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_46844.dir/link.txt --verbose=1]
ignore line: [/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc -v CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj -o cmTC_46844 ]
ignore line: [Using built-in specs.]
ignore line: [COLLECT_GCC=/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-gcc]
ignore line: [COLLECT_LTO_WRAPPER=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper]
@ -157,13 +157,13 @@ Parsed C implicit link information from above output:
ignore line: [gcc version 9.1.0 (GCC) ]
ignore line: [COMPILER_PATH=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/]
ignore line: [LIBRARY_PATH=/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib/]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'cmTC_e11fa' '-mcpu=68000']
link line: [ /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/collect2 -plugin /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/liblto_plugin.so -plugin-opt=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper -plugin-opt=-fresolution=/tmp/cc8x2spZ.res -plugin-opt=-pass-through=-lgcc -plugin-opt=-pass-through=-lc -plugin-opt=-pass-through=-lretrocrt -plugin-opt=-pass-through=-lInterface -elf2mac -q -undefined=_consolewrite -o cmTC_e11fa -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0 -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj --start-group -lgcc -lc -lretrocrt -lInterface --end-group]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'cmTC_46844' '-mcpu=68000']
link line: [ /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/collect2 -plugin /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/liblto_plugin.so -plugin-opt=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper -plugin-opt=-fresolution=/tmp/ccExJbHq.res -plugin-opt=-pass-through=-lgcc -plugin-opt=-pass-through=-lc -plugin-opt=-pass-through=-lretrocrt -plugin-opt=-pass-through=-lInterface -elf2mac -q -undefined=_consolewrite -o cmTC_46844 -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0 -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj --start-group -lgcc -lc -lretrocrt -lInterface --end-group]
arg [/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/collect2] ==> ignore
arg [-plugin] ==> ignore
arg [/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/liblto_plugin.so] ==> ignore
arg [-plugin-opt=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper] ==> ignore
arg [-plugin-opt=-fresolution=/tmp/cc8x2spZ.res] ==> ignore
arg [-plugin-opt=-fresolution=/tmp/ccExJbHq.res] ==> ignore
arg [-plugin-opt=-pass-through=-lgcc] ==> ignore
arg [-plugin-opt=-pass-through=-lc] ==> ignore
arg [-plugin-opt=-pass-through=-lretrocrt] ==> ignore
@ -172,10 +172,10 @@ Parsed C implicit link information from above output:
arg [-q] ==> ignore
arg [-undefined=_consolewrite] ==> ignore
arg [-o] ==> ignore
arg [cmTC_e11fa] ==> ignore
arg [cmTC_46844] ==> ignore
arg [-L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0] ==> dir [/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0]
arg [-L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib] ==> dir [/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib]
arg [CMakeFiles/cmTC_e11fa.dir/CMakeCCompilerABI.c.obj] ==> ignore
arg [CMakeFiles/cmTC_46844.dir/CMakeCCompilerABI.c.obj] ==> ignore
arg [--start-group] ==> ignore
arg [-lgcc] ==> lib [gcc]
arg [-lc] ==> lib [c]
@ -192,13 +192,13 @@ Parsed C implicit link information from above output:
Determining if the CXX compiler works passed with the following output:
Change Dir: /home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp
Run Build Command(s):/usr/bin/make cmTC_f76ee/fast && /usr/bin/make -f CMakeFiles/cmTC_f76ee.dir/build.make CMakeFiles/cmTC_f76ee.dir/build
Run Build Command(s):/usr/bin/make cmTC_5884e/fast && /usr/bin/make -f CMakeFiles/cmTC_5884e.dir/build.make CMakeFiles/cmTC_5884e.dir/build
make[1]: Entering directory '/home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp'
Building CXX object CMakeFiles/cmTC_f76ee.dir/testCXXCompiler.cxx.obj
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++ -o CMakeFiles/cmTC_f76ee.dir/testCXXCompiler.cxx.obj -c /home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp/testCXXCompiler.cxx
Linking CXX executable cmTC_f76ee
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_f76ee.dir/link.txt --verbose=1
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++ CMakeFiles/cmTC_f76ee.dir/testCXXCompiler.cxx.obj -o cmTC_f76ee
Building CXX object CMakeFiles/cmTC_5884e.dir/testCXXCompiler.cxx.obj
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++ -o CMakeFiles/cmTC_5884e.dir/testCXXCompiler.cxx.obj -c /home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp/testCXXCompiler.cxx
Linking CXX executable cmTC_5884e
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_5884e.dir/link.txt --verbose=1
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++ CMakeFiles/cmTC_5884e.dir/testCXXCompiler.cxx.obj -o cmTC_5884e
make[1]: Leaving directory '/home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp'
@ -206,18 +206,18 @@ make[1]: Leaving directory '/home/camh/Documents/Retro68kApps/NuklearQuickDraw/b
Detecting CXX compiler ABI info compiled with the following output:
Change Dir: /home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp
Run Build Command(s):/usr/bin/make cmTC_cda93/fast && /usr/bin/make -f CMakeFiles/cmTC_cda93.dir/build.make CMakeFiles/cmTC_cda93.dir/build
Run Build Command(s):/usr/bin/make cmTC_b936c/fast && /usr/bin/make -f CMakeFiles/cmTC_b936c.dir/build.make CMakeFiles/cmTC_b936c.dir/build
make[1]: Entering directory '/home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp'
Building CXX object CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++ -v -o CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj -c /usr/share/cmake-3.16/Modules/CMakeCXXCompilerABI.cpp
Building CXX object CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++ -v -o CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj -c /usr/share/cmake-3.16/Modules/CMakeCXXCompilerABI.cpp
Using built-in specs.
COLLECT_GCC=/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++
Target: m68k-apple-macos
Configured with: /home/camh/Retro68/gcc/configure --target=m68k-apple-macos --prefix=/home/camh/Retro68-build/toolchain/ --enable-languages=c,c++ --with-arch=m68k --with-cpu=m68000 --disable-libssp MAKEINFO=missing
Thread model: single
gcc version 9.1.0 (GCC)
COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj' '-c' '-mcpu=68000'
/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/cc1plus -quiet -v -Wno-trigraphs /usr/share/cmake-3.16/Modules/CMakeCXXCompilerABI.cpp -quiet -dumpbase CMakeCXXCompilerABI.cpp -mcpu=68000 -auxbase-strip CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj -version -o /tmp/ccF02m1E.s
COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj' '-c' '-mcpu=68000'
/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/cc1plus -quiet -v -Wno-trigraphs /usr/share/cmake-3.16/Modules/CMakeCXXCompilerABI.cpp -quiet -dumpbase CMakeCXXCompilerABI.cpp -mcpu=68000 -auxbase-strip CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj -version -o /tmp/ccVxJrO2.s
GNU C++14 (GCC) version 9.1.0 (m68k-apple-macos)
compiled by GNU C version 9.3.0, GMP version 6.2.0, MPFR version 4.0.2, MPC version 1.1.0, isl version none
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
@ -235,14 +235,14 @@ GNU C++14 (GCC) version 9.1.0 (m68k-apple-macos)
compiled by GNU C version 9.3.0, GMP version 6.2.0, MPFR version 4.0.2, MPC version 1.1.0, isl version none
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: 5b31867a30cfa7e65d4bce12c39f8a21
COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj' '-c' '-mcpu=68000'
/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/as -mcpu=68000 -o CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj /tmp/ccF02m1E.s
COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj' '-c' '-mcpu=68000'
/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/as -mcpu=68000 -o CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj /tmp/ccVxJrO2.s
COMPILER_PATH=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/
LIBRARY_PATH=/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib/
COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj' '-c' '-mcpu=68000'
Linking CXX executable cmTC_cda93
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_cda93.dir/link.txt --verbose=1
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++ -v CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj -o cmTC_cda93
COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj' '-c' '-mcpu=68000'
Linking CXX executable cmTC_b936c
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_b936c.dir/link.txt --verbose=1
/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++ -v CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj -o cmTC_b936c
Using built-in specs.
COLLECT_GCC=/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++
COLLECT_LTO_WRAPPER=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper
@ -252,9 +252,9 @@ Thread model: single
gcc version 9.1.0 (GCC)
COMPILER_PATH=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/
LIBRARY_PATH=/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib/
COLLECT_GCC_OPTIONS='-v' '-o' 'cmTC_cda93' '-mcpu=68000'
/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/collect2 -plugin /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/liblto_plugin.so -plugin-opt=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper -plugin-opt=-fresolution=/tmp/ccFpWhb8.res -plugin-opt=-pass-through=-lgcc -plugin-opt=-pass-through=-lc -plugin-opt=-pass-through=-lretrocrt -plugin-opt=-pass-through=-lInterface -elf2mac -q -undefined=_consolewrite -o cmTC_cda93 -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0 -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj -lstdc++ -lm --start-group -lgcc -lc -lretrocrt -lInterface --end-group
COLLECT_GCC_OPTIONS='-v' '-o' 'cmTC_cda93' '-mcpu=68000'
COLLECT_GCC_OPTIONS='-v' '-o' 'cmTC_b936c' '-mcpu=68000'
/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/collect2 -plugin /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/liblto_plugin.so -plugin-opt=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper -plugin-opt=-fresolution=/tmp/cc7wz44u.res -plugin-opt=-pass-through=-lgcc -plugin-opt=-pass-through=-lc -plugin-opt=-pass-through=-lretrocrt -plugin-opt=-pass-through=-lInterface -elf2mac -q -undefined=_consolewrite -o cmTC_b936c -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0 -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj -lstdc++ -lm --start-group -lgcc -lc -lretrocrt -lInterface --end-group
COLLECT_GCC_OPTIONS='-v' '-o' 'cmTC_b936c' '-mcpu=68000'
make[1]: Leaving directory '/home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp'
@ -282,18 +282,18 @@ Parsed CXX implicit link information from above output:
link line regex: [^( *|.*[/\])(m68k-apple-macos-ld|CMAKE_LINK_STARTFILE-NOTFOUND|([^/\]+-)?ld|collect2)[^/\]*( |$)]
ignore line: [Change Dir: /home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp]
ignore line: []
ignore line: [Run Build Command(s):/usr/bin/make cmTC_cda93/fast && /usr/bin/make -f CMakeFiles/cmTC_cda93.dir/build.make CMakeFiles/cmTC_cda93.dir/build]
ignore line: [Run Build Command(s):/usr/bin/make cmTC_b936c/fast && /usr/bin/make -f CMakeFiles/cmTC_b936c.dir/build.make CMakeFiles/cmTC_b936c.dir/build]
ignore line: [make[1]: Entering directory '/home/camh/Documents/Retro68kApps/NuklearQuickDraw/build/CMakeFiles/CMakeTmp']
ignore line: [Building CXX object CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj]
ignore line: [/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++ -v -o CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj -c /usr/share/cmake-3.16/Modules/CMakeCXXCompilerABI.cpp]
ignore line: [Building CXX object CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj]
ignore line: [/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++ -v -o CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj -c /usr/share/cmake-3.16/Modules/CMakeCXXCompilerABI.cpp]
ignore line: [Using built-in specs.]
ignore line: [COLLECT_GCC=/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++]
ignore line: [Target: m68k-apple-macos]
ignore line: [Configured with: /home/camh/Retro68/gcc/configure --target=m68k-apple-macos --prefix=/home/camh/Retro68-build/toolchain/ --enable-languages=c c++ --with-arch=m68k --with-cpu=m68000 --disable-libssp MAKEINFO=missing]
ignore line: [Thread model: single]
ignore line: [gcc version 9.1.0 (GCC) ]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj' '-c' '-mcpu=68000']
ignore line: [ /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/cc1plus -quiet -v -Wno-trigraphs /usr/share/cmake-3.16/Modules/CMakeCXXCompilerABI.cpp -quiet -dumpbase CMakeCXXCompilerABI.cpp -mcpu=68000 -auxbase-strip CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj -version -o /tmp/ccF02m1E.s]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj' '-c' '-mcpu=68000']
ignore line: [ /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/cc1plus -quiet -v -Wno-trigraphs /usr/share/cmake-3.16/Modules/CMakeCXXCompilerABI.cpp -quiet -dumpbase CMakeCXXCompilerABI.cpp -mcpu=68000 -auxbase-strip CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj -version -o /tmp/ccVxJrO2.s]
ignore line: [GNU C++14 (GCC) version 9.1.0 (m68k-apple-macos)]
ignore line: [ compiled by GNU C version 9.3.0 GMP version 6.2.0 MPFR version 4.0.2 MPC version 1.1.0 isl version none]
ignore line: [GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072]
@ -311,14 +311,14 @@ Parsed CXX implicit link information from above output:
ignore line: [ compiled by GNU C version 9.3.0 GMP version 6.2.0 MPFR version 4.0.2 MPC version 1.1.0 isl version none]
ignore line: [GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072]
ignore line: [Compiler executable checksum: 5b31867a30cfa7e65d4bce12c39f8a21]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj' '-c' '-mcpu=68000']
ignore line: [ /home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/as -mcpu=68000 -o CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj /tmp/ccF02m1E.s]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj' '-c' '-mcpu=68000']
ignore line: [ /home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/as -mcpu=68000 -o CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj /tmp/ccVxJrO2.s]
ignore line: [COMPILER_PATH=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/]
ignore line: [LIBRARY_PATH=/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib/]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj' '-c' '-mcpu=68000']
ignore line: [Linking CXX executable cmTC_cda93]
ignore line: [/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_cda93.dir/link.txt --verbose=1]
ignore line: [/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++ -v CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj -o cmTC_cda93 ]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj' '-c' '-mcpu=68000']
ignore line: [Linking CXX executable cmTC_b936c]
ignore line: [/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_b936c.dir/link.txt --verbose=1]
ignore line: [/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++ -v CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj -o cmTC_b936c ]
ignore line: [Using built-in specs.]
ignore line: [COLLECT_GCC=/home/camh/Retro68-build/toolchain/bin/m68k-apple-macos-g++]
ignore line: [COLLECT_LTO_WRAPPER=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper]
@ -328,13 +328,13 @@ Parsed CXX implicit link information from above output:
ignore line: [gcc version 9.1.0 (GCC) ]
ignore line: [COMPILER_PATH=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/bin/]
ignore line: [LIBRARY_PATH=/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/:/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib/]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'cmTC_cda93' '-mcpu=68000']
link line: [ /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/collect2 -plugin /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/liblto_plugin.so -plugin-opt=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper -plugin-opt=-fresolution=/tmp/ccFpWhb8.res -plugin-opt=-pass-through=-lgcc -plugin-opt=-pass-through=-lc -plugin-opt=-pass-through=-lretrocrt -plugin-opt=-pass-through=-lInterface -elf2mac -q -undefined=_consolewrite -o cmTC_cda93 -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0 -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj -lstdc++ -lm --start-group -lgcc -lc -lretrocrt -lInterface --end-group]
ignore line: [COLLECT_GCC_OPTIONS='-v' '-o' 'cmTC_b936c' '-mcpu=68000']
link line: [ /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/collect2 -plugin /home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/liblto_plugin.so -plugin-opt=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper -plugin-opt=-fresolution=/tmp/cc7wz44u.res -plugin-opt=-pass-through=-lgcc -plugin-opt=-pass-through=-lc -plugin-opt=-pass-through=-lretrocrt -plugin-opt=-pass-through=-lInterface -elf2mac -q -undefined=_consolewrite -o cmTC_b936c -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0 -L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj -lstdc++ -lm --start-group -lgcc -lc -lretrocrt -lInterface --end-group]
arg [/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/collect2] ==> ignore
arg [-plugin] ==> ignore
arg [/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/liblto_plugin.so] ==> ignore
arg [-plugin-opt=/home/camh/Retro68-build/toolchain/libexec/gcc/m68k-apple-macos/9.1.0/lto-wrapper] ==> ignore
arg [-plugin-opt=-fresolution=/tmp/ccFpWhb8.res] ==> ignore
arg [-plugin-opt=-fresolution=/tmp/cc7wz44u.res] ==> ignore
arg [-plugin-opt=-pass-through=-lgcc] ==> ignore
arg [-plugin-opt=-pass-through=-lc] ==> ignore
arg [-plugin-opt=-pass-through=-lretrocrt] ==> ignore
@ -343,10 +343,10 @@ Parsed CXX implicit link information from above output:
arg [-q] ==> ignore
arg [-undefined=_consolewrite] ==> ignore
arg [-o] ==> ignore
arg [cmTC_cda93] ==> ignore
arg [cmTC_b936c] ==> ignore
arg [-L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0] ==> dir [/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0]
arg [-L/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib] ==> dir [/home/camh/Retro68-build/toolchain/lib/gcc/m68k-apple-macos/9.1.0/../../../../m68k-apple-macos/lib]
arg [CMakeFiles/cmTC_cda93.dir/CMakeCXXCompilerABI.cpp.obj] ==> ignore
arg [CMakeFiles/cmTC_b936c.dir/CMakeCXXCompilerABI.cpp.obj] ==> ignore
arg [-lstdc++] ==> lib [stdc++]
arg [-lm] ==> lib [m]
arg [--start-group] ==> ignore

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -1,4 +1,11 @@
// TODO:
// - IN PROGRESS new message window -- needs to blank out messages, then needs fixes on new mac end
// - chat during the day for a few minutes and figure out small issues
// - start writing blog posts
// - get new messages in other chats and display some sort of alert
// - need timeout on serial messages in case the computer at the other end dies (prevent hard reset)
// - delete doesnt work right (leaves characters at end of string)
// - move app-specific code to distinct file
void aFailed(char *file, int line) {
@ -198,9 +205,9 @@ Boolean checkCollision(struct nk_rect window) {
window.x + window.w > mouse_x &&
window.y < mouse_y &&
window.y + window.h > mouse_y);
}
// UI setup and event handling goes here
static void nuklearApp(struct nk_context *ctx) {
// prompt the user for the graphql instance
@ -271,7 +278,6 @@ static void nuklearApp(struct nk_context *ctx) {
sendNewChat = 0;
forceRedraw = 2;
// sendIPAddressToCoprocessor();
sprintf(activeChat, new_message_input_buffer);
}
@ -344,12 +350,10 @@ static void nuklearApp(struct nk_context *ctx) {
nk_layout_row_begin(ctx, NK_STATIC, 12, 1);
{
for (int i = 0; i < activeMessageCounter; i++) {
nk_layout_row_push(ctx, 305);
// message label
// writeSerialPortDebug(boutRefNum, "create label!");
// writeSerialPortDebug(boutRefNum, activeChatMessages[i]);
nk_label(ctx, activeChatMessages[i], NK_TEXT_ALIGN_LEFT);
}
@ -373,19 +377,20 @@ static void nuklearApp(struct nk_context *ctx) {
struct nk_context* initializeNuklearApp() {
sprintf(activeChat, "no active chat");
struct nk_context *ctx;
graphql_input_window_size = nk_rect(WINDOW_WIDTH / 4, WINDOW_HEIGHT / 4, WINDOW_WIDTH / 2, 120);
chats_window_size = nk_rect(0, 0, 180, WINDOW_HEIGHT);
messages_window_size = nk_rect(180, 0, 330, WINDOW_HEIGHT - 36);
message_input_window_size = nk_rect(180, WINDOW_HEIGHT - 36, 330, 36);
ctx = nk_quickdraw_init(WINDOW_WIDTH, WINDOW_HEIGHT);
struct nk_context *ctx = nk_quickdraw_init(WINDOW_WIDTH, WINDOW_HEIGHT);
nk_input_begin(ctx);
nk_input_end(ctx);
nuklearApp(ctx);
nk_quickdraw_render(FrontWindow(), ctx);
nk_clear(ctx);
sprintf(ip_input_buffer, "http://"); // doesn't work due to bug
sprintf(ip_input_buffer, "http://"); // doesn't work due to bug, see variable definition
return ctx;
}

View File

@ -43,7 +43,7 @@ NK_API NkQuickDrawFont* nk_quickdraw_font_create_from_file();
*
* ===============================================================
*/
#define MAX_MEMORY_IN_KB 4
#ifdef NK_QUICKDRAW_IMPLEMENTATION
#ifndef NK_QUICKDRAW_TEXT_MAX
#define NK_QUICKDRAW_TEXT_MAX 256
@ -256,6 +256,7 @@ NK_API void nk_quickdraw_del_image(struct nk_image* image) {
free(image);
}
// NOTE: you will need to generate this yourself!
short widthFor12ptFont[128] = {
0,
10,
@ -387,16 +388,9 @@ short widthFor12ptFont[128] = {
8
};
// note: if this produces a greater value than the actual length of the text,
// the cursor will walk off to the right
// too small, it will precede the end of the text
// TODO: fully convert
// TODO: assuming system font for v1, support other fonts in v2
// doing this in a "fast" way by using a precomputed table for a 12pt font
static short nk_quickdraw_font_get_text_width(nk_handle handle, short height, const char *text, short len) {
// // writeSerialPortDebug(boutRefNum, "nk_quickdraw_font_get_text_width");
if (!text || len == 0) {
return 0;
@ -414,8 +408,6 @@ static short nk_quickdraw_font_get_text_width(nk_handle handle, short height, co
static int _get_text_width(const char *text, int len) {
// // writeSerialPortDebug(boutRefNum, "nk_quickdraw_font_get_text_width");
if (!text || len == 0) {
return 0;
@ -448,7 +440,7 @@ static int nk_color_to_quickdraw_bw_color(struct nk_color color) {
char stringMagicColorNumber[255];
sprintf(stringMagicColorNumber, "stringMagicColorNumber: %f", magicColorNumber);
// writeSerialPortDebug(boutRefNum, stringMagicColorNumber);
writeSerialPortDebug(boutRefNum, stringMagicColorNumber);
#endif
if (magicColorNumber > 37) {
@ -456,7 +448,7 @@ static int nk_color_to_quickdraw_bw_color(struct nk_color color) {
return blackColor;
}
return blackColor;//whiteColor;
return blackColor;
}
// i split this in to a 2nd routine because we can use the various shades of gray when filling rectangles and whatnot
@ -468,8 +460,6 @@ static Pattern nk_color_to_quickdraw_color(struct nk_color color) {
uint8_t red;
uint8_t blue;
uint8_t green;
float magicColorNumber = color.r * 0.299 + color.g * 0.587 + color.b * 0.114;
if (magicColorNumber > 150) {
@ -507,16 +497,6 @@ NK_API NkQuickDrawFont* nk_quickdraw_font_create_from_file() {
NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
long start;
long end;
long total;
start = TickCount();
long renderTime1;
long renderTime2;
long renderTime3;
void *cmds = nk_buffer_memory(&ctx->memory);
// do not render if the buffer did not change from the previous rendering run
@ -524,7 +504,7 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_NOP");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_NOP");
#endif
return;
@ -534,80 +514,29 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
const struct nk_command *cmd = 0;
// if (!lastEventWasKey) {
OpenPort(&gMainOffScreen.BWPort);
SetPort(&gMainOffScreen.BWPort);
SetPortBits(&gMainOffScreen.BWBits);
// EraseRect(&gMainOffScreen.bounds);
// int theNum;
// GetFNum('Chicago', theNum);
// // do this twice, once now, and once after the port is switched to the offscreen
// TextFont(theNum);
// TextSize(12);
// } else {
// SetPort(window);
// int theNum;
// GetFNum('Chicago', theNum);
// // do this twice, once now, and once after the port is switched to the offscreen
// TextFont(theNum);
// TextSize(12);
// }
end = TickCount();
total = end - start;
renderTime1 = total;// / 60.0;
start = TickCount();
nk_foreach(cmd, ctx) {
int color;
// ForeColor(blackColor);
// if (lastEventWasKey && cmd->type == NK_COMMAND_TEXT) {
// // writeSerialPortDebug(boutRefNum, "FAST INPUT");
// const struct nk_command_text *t = (const struct nk_command_text*)cmd;
// #ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// // writeSerialPortDebug(boutRefNum, "NK_COMMAND_TEXT");
// char log[255];
// sprintf(log, "%f: %c, %d", (int)t->height, &t->string, (int)t->length);
// // writeSerialPortDebug(boutRefNum, log);
// #endif
// MoveTo((int)t->x + _get_text_width(t->string, (int)t->length - 1), (int)t->y + (int)t->height);
// // DrawText((const char*)t->string, 0, (int)t->length);
// PenSize(1.0, 1.0);
// DrawChar(t->string[t->length - 1]);
// } else if (!lastEventWasKey) {
// writeSerialPortDebug(boutRefNum, "SLOW INPUT");
switch (cmd->type) {
case NK_COMMAND_NOP:
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_NOP");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_NOP");
#endif
break;
case NK_COMMAND_SCISSOR: {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_SCISSOR");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_SCISSOR");
#endif
const struct nk_command_scissor *s =(const struct nk_command_scissor*)cmd;
@ -624,17 +553,15 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
break;
case NK_COMMAND_LINE: {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_LINE");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_LINE");
#endif
const struct nk_command_line *l = (const struct nk_command_line *)cmd;
color = nk_color_to_quickdraw_bw_color(l->color);
// great reference: http://mirror.informatimago.com/next/developer.apple.com/documentation/mac/QuickDraw/QuickDraw-60.html
// al_draw_line((float)l->begin.x, (float)l->begin.y, (float)l->end.x, (float)l->end.y, color, (float)l->line_thickness); // TODO: look up and convert al_draw_line
ForeColor(color);
PenSize((int)l->line_thickness, (int)l->line_thickness);
MoveTo((int)l->begin.x, (int)l->begin.y);
@ -647,7 +574,7 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_RECT");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_RECT");
#endif
// http://mirror.informatimago.com/next/developer.apple.com/documentation/mac/QuickDraw/QuickDraw-102.html#MARKER-9-372
@ -671,10 +598,9 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
break;
case NK_COMMAND_RECT_FILLED: {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_RECT_FILLED");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_RECT_FILLED");
#endif
const struct nk_command_rect_filled *r = (const struct nk_command_rect_filled *)cmd;
@ -702,7 +628,7 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_CIRCLE");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_CIRCLE");
#endif
const struct nk_command_circle *c = (const struct nk_command_circle *)cmd;
@ -722,10 +648,9 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
break;
case NK_COMMAND_CIRCLE_FILLED: {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_CIRCLE_FILLED");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_CIRCLE_FILLED");
#endif
const struct nk_command_circle_filled *c = (const struct nk_command_circle_filled *)cmd;
@ -750,10 +675,9 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
break;
case NK_COMMAND_TRIANGLE: {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_TRIANGLE");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_TRIANGLE");
#endif
const struct nk_command_triangle *t = (const struct nk_command_triangle*)cmd;
@ -774,7 +698,7 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_TRIANGLE_FILLED");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_TRIANGLE_FILLED");
#endif
const struct nk_command_triangle_filled *t = (const struct nk_command_triangle_filled *)cmd;
@ -798,10 +722,9 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
break;
case NK_COMMAND_POLYGON: {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_POLYGON");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_POLYGON");
#endif
const struct nk_command_polygon *p = (const struct nk_command_polygon*)cmd;
@ -821,7 +744,6 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
if (i == p->point_count - 1) {
LineTo(p->points[0].x, p->points[0].y);
}
}
@ -833,7 +755,7 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_POLYGON_FILLED");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_POLYGON_FILLED");
#endif
const struct nk_command_polygon *p = (const struct nk_command_polygon*)cmd;
@ -872,7 +794,7 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_POLYLINE");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_POLYLINE");
#endif
// this is similar to polygons except the polygon does not get closed to the 0th point
@ -901,10 +823,10 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_TEXT");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_TEXT");
char log[255];
sprintf(log, "%f: %c, %d", (int)t->height, &t->string, (int)t->length);
// writeSerialPortDebug(boutRefNum, log);
writeSerialPortDebug(boutRefNum, log);
#endif
color = nk_color_to_quickdraw_bw_color(t->foreground);
@ -913,8 +835,6 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
PenSize(1.0, 1.0);
DrawText((const char*)t->string, 0, (int)t->length);
// DrawChar(t->string[t->length - 1]);
}
break;
@ -922,7 +842,7 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_CURVE");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_CURVE");
#endif
const struct nk_command_curve *q = (const struct nk_command_curve *)cmd;
@ -941,7 +861,7 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_ARC");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_ARC");
#endif
const struct nk_command_arc *a = (const struct nk_command_arc *)cmd;
@ -966,7 +886,7 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_IMAGE");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_IMAGE");
#endif
const struct nk_command_image *i = (const struct nk_command_image *)cmd;
@ -1002,41 +922,17 @@ NK_API void nk_quickdraw_render(WindowPtr window, struct nk_context *ctx) {
#ifdef NK_QUICKDRAW_GRAPHICS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "NK_COMMAND_RECT_MULTI_COLOR/NK_COMMAND_ARC_FILLED/default");
writeSerialPortDebug(boutRefNum, "NK_COMMAND_RECT_MULTI_COLOR/NK_COMMAND_ARC_FILLED/default");
#endif
break;
}
// }
}
end = TickCount();
total = end - start;
renderTime2 = total;// / 60.0;
start = TickCount();
// if (!lastEventWasKey) {
SetPort(window);
// our offscreen bitmap is the same size as our port rectangle, so we
// get away with using the portRect sizing for source and destination
CopyBits(&gMainOffScreen.bits->portBits, &window->portBits, &window->portRect, &window->portRect, srcCopy, 0L);
// }
end = TickCount();
total = end - start;
renderTime3 = total;// / 60.0;
start = TickCount();
// char logx[255];
// sprintf(logx, "nk_quickdraw_render() renderTime1 (pre-render) %ld, renderTime2 (render loop) %ld, renderTime3 (post-render) %ld ticks to execute\n", renderTime1, renderTime2, renderTime3);
// // writeSerialPortDebug(boutRefNum, logx);
lastEventWasKey = 0;
}
NK_API int nk_quickdraw_handle_event(EventRecord *event, struct nk_context *nuklear_context) {
@ -1067,7 +963,7 @@ NK_API int nk_quickdraw_handle_event(EventRecord *event, struct nk_context *nukl
#ifdef NK_QUICKDRAW_EVENTS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "mouseMovedMessage");
writeSerialPortDebug(boutRefNum, "mouseMovedMessage");
#endif
@ -1086,13 +982,13 @@ NK_API int nk_quickdraw_handle_event(EventRecord *event, struct nk_context *nukl
case mouseUp:
#ifdef NK_QUICKDRAW_EVENTS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "mouseUp!!!");
writeSerialPortDebug(boutRefNum, "mouseUp!!!");
#endif
case mouseDown: {
#ifdef NK_QUICKDRAW_EVENTS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "mouseUp/Down");
writeSerialPortDebug(boutRefNum, "mouseUp/Down");
#endif
short part = FindWindow(event->where, &window);
@ -1103,7 +999,7 @@ NK_API int nk_quickdraw_handle_event(EventRecord *event, struct nk_context *nukl
// TODO need to figure this out
#ifdef NK_QUICKDRAW_EVENTS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "mouseUp/Down IN DEFAULT ZONE!!!!");
writeSerialPortDebug(boutRefNum, "mouseUp/Down IN DEFAULT ZONE!!!!");
#endif
// this converts the offset of the window to the actual location of the mouse within the window
@ -1115,19 +1011,19 @@ NK_API int nk_quickdraw_handle_event(EventRecord *event, struct nk_context *nukl
#ifdef NK_QUICKDRAW_EVENTS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "no event location for mouse!!!!");
writeSerialPortDebug(boutRefNum, "no event location for mouse!!!!");
#endif
return 1;
}
int x = tempPoint.h;
int y = tempPoint.v;
//#ifdef NK_QUICKDRAW_EVENTS_DEBUGGING
#ifdef NK_QUICKDRAW_EVENTS_DEBUGGING
char logx[255];
sprintf(logx, "mouse location at time of click h: %d, v: %d, is mouse down: %d", x, y, event->what == mouseDown);
writeSerialPortDebug(boutRefNum, logx);
//#endif
#endif
// nk_input_motion(nuklear_context, x, y); // you can enable this if you don't want to use motion tracking
// in the Mac event loop handler as in the nuklear quickdraw sample, and this will allow mouse clicks to
@ -1231,10 +1127,10 @@ NK_API int nk_quickdraw_handle_event(EventRecord *event, struct nk_context *nukl
nk_input_key(nuklear_context, NK_KEY_SCROLL_END, isKeyDown);
} else {
// #ifdef NK_QUICKDRAW_EVENTS_DEBUGGING
#ifdef NK_QUICKDRAW_EVENTS_DEBUGGING
//writeSerialPortDebug(boutRefNum, "default keydown/autokey event");
// #endif
writeSerialPortDebug(boutRefNum, "default keydown/autokey event");
#endif
nk_input_char(nuklear_context, charKey);
}
@ -1247,7 +1143,7 @@ NK_API int nk_quickdraw_handle_event(EventRecord *event, struct nk_context *nukl
default: {
#ifdef NK_QUICKDRAW_EVENTS_DEBUGGING
// writeSerialPortDebug(boutRefNum, "default unhandled event");
writeSerialPortDebug(boutRefNum, "default unhandled event");
#endif
return 1;
@ -1286,9 +1182,9 @@ NK_API struct nk_context* nk_quickdraw_init(unsigned int width, unsigned int hei
NkQuickDrawFont *quickdrawfont = nk_quickdraw_font_create_from_file();
struct nk_user_font *font = &quickdrawfont->nk;
last = calloc(1, 64 * 1024);
buf = calloc(1, 64 * 1024);
nk_init_fixed(&quickdraw.nuklear_context, buf, 64 * 1024, font);
last = calloc(1, MAX_MEMORY_IN_KB * 1024);
buf = calloc(1, MAX_MEMORY_IN_KB * 1024);
nk_init_fixed(&quickdraw.nuklear_context, buf, MAX_MEMORY_IN_KB * 1024, font);
// nk_init_default(&quickdraw.nuklear_context, font);
nk_style_push_font(&quickdraw.nuklear_context, font);
@ -1372,7 +1268,7 @@ NK_API struct nk_context* nk_quickdraw_init(unsigned int width, unsigned int hei
button->userdata = nk_handle_ptr(0);
button->text_alignment = NK_TEXT_LEFT;
button->border = 1;
button->rounding = 4;
button->rounding = 10;
button->draw_begin = 0;
button->draw_end = 0;