Modify RPGVXAce Code Editor Font

Make SciLexer.dll

  1. Download $('a[href$=".zip"]').href
  2. Open scintilla/win32/ScintillaWin.cxx#L1796
    1. Change font face
      case SCI_STYLESETFONT:
        return ScintillaBase::WndProc(SCI_STYLESETFONT, wParam, reinterpret_cast<LPARAM>("等距更纱黑体 SC"));
      
    2. Change font size
      case SCI_STYLESETSIZE:
        return ScintillaBase::WndProc(SCI_STYLESETSIZE, wParam, lParam+1);
      
    3. Enable DirectWrite
        case SCI_STYLESETFONT:
          if (technology != static_cast<int>(SC_TECHNOLOGY_DIRECTWRITE)) {
            if (static_cast<int>(SC_TECHNOLOGY_DIRECTWRITE) > SC_TECHNOLOGY_DEFAULT) {
      #if defined(USE_D2D)
              LoadD2D();
      #endif
            } else {
              bidirectional = EditModel::Bidirectional::bidiDisabled;
            }
      #if defined(USE_D2D)
              DropRenderTarget();
      #endif
            technology = static_cast<int>(SC_TECHNOLOGY_DIRECTWRITE);
            // Invalidate all cached information including layout.
            DropGraphics(true);
            InvalidateStyleRedraw();
          }
          return ScintillaBase::WndProc(SCI_STYLESETFONT, wParam, reinterpret_cast<LPARAM>("等距更纱黑体 SC"));
      
  3. cd ../../lexers, delete unnecessary languages.
  4. cd ../scripts
    python LexGen.py
    
  5. cd ..
    nmake -f scintilla.mak
    
  6. copy bin\SciLexer.dll $env:SteamLibrary\steamapps\common\RPGVXAce\SciLexer.dll
    

© 2019 hyrious