<commit_before>/*! @file */

#ifndef _PROFILEAPP_H_
#define _PROFILEAPP_H_

#include <StaticDisplayApp.h>

/**
 * @class ProfileApp
 * @author <NAME>
 * @brief Displays profile/contact information on the display.
 */
class ProfileApp : public StaticDisplayApp
{
public:
  ProfileApp()
      : StaticDisplayApp("Profile")
  {
  }

  virtual ~ProfileApp()
  {
  }

  /**
   * @copydoc App::run
   */
  virtual void run()
  {
    App::run();

    /* Keep backlight on */
    m_manager->feedBacklight(BACKLIGHT_STATE_DIM);
  }

protected:
  /**
   * @copydoc StaticDisplayApp::drawPortrait
   */
  virtual void drawPortrait()
  {
    m_badge->display().setTextColor(ILI9341_YELLOW);
    m_badge->display().setTextSize(6);
    m_badge->display().println("Dan\nNixon\n");

    m_badge->display().setTextSize(3);
    m_badge->display().setTextColor(ILI9341_CYAN);
    m_badge->display().println("@technoducky");
    m_badge->display().setTextColor(ILI9341_BLUE);
    m_badge->display().println("dan-nixon.com\n");

    m_badge->display().setTextColor(ILI9341_RED);
    m_badge->display().setTextSize(3);
    m_badge->display().println("Code Monkey, Electronics\nEngineer, Mad\nScientist.");
  }

  /**
   * @copydoc StaticDisplayApp::drawLandscape
   */
  virtual void drawLandscape()
  {
    m_badge->display().setTextColor(ILI9341_YELLOW);
    m_badge->display().setTextSize(5);
    m_badge->display().println("<NAME>");

    m_badge->display().setTextSize(3);
    m_badge->display().println();

    m_badge->display().setTextSize(3);
    m_badge->display().setTextColor(ILI9341_CYAN);
    m_badge->display().println("@technoducky");
    m_badge->display().setTextColor(ILI9341_BLUE);
    m_badge->display().println("dan-nixon.com\n");

    m_badge->display().setTextColor(ILI9341_RED);
    m_badge->display().setTextSize(3);
    m_badge->display().println("Code Monkey,\nElectronics\nEngineer,\nMad Scientist.");
  }
};
<commit_msg>add macros to profile app for different profiles<commit_after>/*! @file */

#ifndef _PROFILEAPP_H_
#define _PROFILEAPP_H_

#include <StaticDisplayApp.h>

#define PROFILE_DAN
/* #define PROFILE_ALISTAIR */

/**
 * @class ProfileApp
 * @author <NAME>
 * @brief Displays profile/contact information on the display.
 *
 * Make sure to uncomment the correct macro for whoever you are.
 */
class ProfileApp : public StaticDisplayApp
{
public:
  ProfileApp()
      : StaticDisplayApp("Profile")
  {
  }

  virtual ~ProfileApp()
  {
  }

  /**
   * @copydoc App::run
   */
  virtual void run()
  {
    App::run();

    /* Keep backlight on */
    m_manager->feedBacklight(BACKLIGHT_STATE_DIM);
  }

protected:
  /**
   * @copydoc StaticDisplayApp::drawPortrait
   */
  virtual void drawPortrait()
  {
#ifdef PROFILE_DAN
    m_badge->display().setTextColor(ILI9341_YELLOW);
    m_badge->display().setTextSize(6);
    m_badge->display().println("Dan\nNixon\n");

    m_badge->display().setTextSize(3);
    m_badge->display().setTextColor(ILI9341_CYAN);
    m_badge->display().println("@technoducky");
    m_badge->display().setTextColor(ILI9341_BLUE);
    m_badge->display().println("dan-nixon.com\n");

    m_badge->display().setTextColor(ILI9341_RED);
    m_badge->display().setTextSize(3);
    m_badge->display().println("Code Monkey, Electronics\nEngineer, Mad\nScientist.");
#endif

#ifdef PROFILE_ALISTAIR
    m_badge->display().setTextColor(ILI9341_YELLOW);
    m_badge->display().setTextSize(4);
    m_badge->display().println("Alistair\n");

    m_badge->display().setTextSize(3);
    m_badge->display().setTextColor(ILI9341_CYAN);
    m_badge->display().println("@alistair");
    m_badge->display().setTextColor(ILI9341_BLUE);
    m_badge->display().println("agm.me.uk\n");

    m_badge->display().setTextColor(ILI9341_RED);
    m_badge->display().setTextSize(3);
    m_badge->display().println("Gibberish\nspeaker from the north\neast.");
#endif
  }

  /**
   * @copydoc StaticDisplayApp::drawLandscape
   */
  virtual void drawLandscape()
  {
#ifdef PROFILE_DAN
    m_badge->display().setTextColor(ILI9341_YELLOW);
    m_badge->display().setTextSize(5);
    m_badge->display().println("<NAME>");

    m_badge->display().setTextSize(3);
    m_badge->display().println();

    m_badge->display().setTextSize(3);
    m_badge->display().setTextColor(ILI9341_CYAN);
    m_badge->display().println("@technoducky");
    m_badge->display().setTextColor(ILI9341_BLUE);
    m_badge->display().println("dan-nixon.com\n");

    m_badge->display().setTextColor(ILI9341_RED);
    m_badge->display().setTextSize(3);
    m_badge->display().println("Code Monkey,\nElectronics\nEngineer,\nMad Scientist.");
#endif

#ifdef PROFILE_ALISTAIR
    m_badge->display().setTextColor(ILI9341_YELLOW);
    m_badge->display().setTextSize(5);
    m_badge->display().println("Alistair");

    m_badge->display().setTextSize(3);
    m_badge->display().println();

    m_badge->display().setTextSize(3);
    m_badge->display().setTextColor(ILI9341_CYAN);
    m_badge->display().println("@alistair");
    m_badge->display().setTextColor(ILI9341_BLUE);
    m_badge->display().println("agm.me.uk\n");

    m_badge->display().setTextColor(ILI9341_RED);
    m_badge->display().setTextSize(3);
    m_badge->display().println("Gibberish speaker\nfrom the north\neast.");
#endif
  }
};

{'fraction_non_alphanumeric': 0.17213270142180095, 'fraction_numerical': 0.02218009478672986, 'mean_word_length': 4.356345177664974, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 83, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7428408', 'n_tokens_mistral': 1982, 'n_tokens_neox': 1881, 'n_words': 220}