Skip to content

Instantly share code, notes, and snippets.

@CatzHoekk
CatzHoekk / rtl.gd
Last active April 12, 2025 21:18
BBCode sanitizer for Godot RichTextLabel
extends RichTextLabel
@export var whitelisted_tags : PackedStringArray = ["url"]
@export_multiline var unsanitized_text: String = """ 1. This text is normal, but [b]this part is bold[/b].
2. You can also make text [i]italic[/i] for emphasis.
3. Or, if needed, [u]underline important words[/u].
4. Combine styles like [b][i]bold and italic[/i][/b].
5. Change text color using names: [color=green]This is green.[/color]
6. Use hex codes for specific colors: [color=#ff8800]This is orange.[/color]
7. [s]Strike through[/s] text that is no longer relevant.
@CatzHoekk
CatzHoekk / enable-picture-in-picture.js
Last active June 20, 2024 19:37
Enables picture in picture on all video elements
// ==UserScript==
// @name Reactivate Picture-in-Picture
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Detects when a video element loads and allows for Picture-in-Picture (Does not actually start PIP mode)
// @author CatzHoek
// @match *://*/*
// @grant none
// ==/UserScript==