Skip to content

Instantly share code, notes, and snippets.

@mridgers
mridgers / mandel.bat
Created February 12, 2012 21:47
Mandelbrot set generator in 332 bytes of batch script (with Unix line endings).
@echo off
setlocal enabledelayedexpansion
set r=set /a
for /l %%y in (-16,1,16) do (
set l=
for /l %%x in (-57,1,21) do (
set u=0
set v=0
set "j=M.-+l$?+*:="'~-. "
for /l %%i in (0,1,15) do (
@mridgers
mridgers / pdbdump.c
Created June 21, 2012 21:19
Small tool to list and query symbols in PDB files.
//------------------------------------------------------------------------------
// pdbdump.c - dump symbols from .pdb and executable files (public domain).
// - to compile; cl.exe /Ox /Zi pdbdump.c
// -
// - Martin Ridgers, pdbdump 'at' fireproofgravy.co.uk
//------------------------------------------------------------------------------
#include <stdio.h>
#include <Windows.h>
#include <DbgHelp.h>
@mridgers
mridgers / thirds.cpp
Created April 30, 2023 09:33
Three column window placement using hot keys
/*
* building;
* cl.exe thirds.cpp /std:c++17 /EHsc /Zi /Ox /link /subsystem:windows
*
* using;
* Win-Ctrl-A : [-1/3-:-1/3-:-1/3-]
* Win-Ctrl-Z : [-1/3-:----2/3----] + fat middle
* Win-Ctrl-W : toggles between top/bottom halves of column from 'A'
*/