Day 78/100 100 Days of Code

Chris DourisChris Douris
1 min read

Combined the Resource struct and the FindResource function to generate a path to the font file. To create the path, I switched from using getBundlePath to getExecutablePath because I am not making a .app executable.

char* FindResource(char *fileLocation)
{
    char *execPath; 
    unsigned int lengthValue = 100;
    getExecutablePath(&execPath, &lengthValue);
    printf("Path %s\n", execPath);

    strcat(execPath, fileLocation);
    return execPath;
}

Then, I spent the rest of the session fixing all the errors to make the application run. The application is now opens a new full screen window and initialises all the components properly.

0
Subscribe to my newsletter

Read articles from Chris Douris directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

Chris Douris
Chris Douris

AKA Chris, is a software developer from Athens, Greece. He started programming with basic when he was very young. He lost interest in programming during school years but after an unsuccessful career in audio, he decided focus on what he really loves which is technology. He loves working with older languages like C and wants to start programming electronics and microcontrollers because he wants to get into embedded systems programming.