How to change floating menu font colors using AppleScript?

To change the background color on a floating menu item I add this to an Apple Script:

		update_menu_item "872364f-987-0989-B551-0876908699" json "{\"BTTMenuItemText\": \"\", \"BTTMenuItemBackgroundColor\": \"0, 0, 0, 255\"}"

What do I need to add to change the font color?

This requires v5.641 or higher:

tell application "BetterTouchTool"
	update_menu_item "60AD82FF-ABAA-4D79-B5C6-4E4058350E34" json "{BTTMenuItemFontColor: '#3355ff', BTTMenuItemFontWeight: 7, BTTMenuItemFontSize: 30}"
end tell

If you use this format you also don't need to escape because BTT allows JSON5

There are also other ways, e.g. you can use HTML to style your text:

tell application "BetterTouchTool"
	update_menu_item "60AD82FF-ABAA-4D79-B5C6-4E4058350E34" json "{BTTMenuAttributedText: '<html><span style=\"font-family: -apple-system, BlinkMacSystemFont; font-size:25px; sans-serif; color:red;\">hello</span></html>' }"
end tell

Thanks,

That was exactly what I needed! :slight_smile: