Folks seem to have success dying entire PBT keys with dye by submerging them in a vat of Rit or Dylon dye. However, you can't make a legend if the whole key is dyed... which gets me thinking: I used to make Ukrainian-style Easter eggs, and the same process could be followed for DIY dye-sublimation without need for an expensive printer or ink (I don't know how much the printers are, but surely a couple packets of dye would cost less?)
When making Ukrainian Easter eggs, hot wax is applied to the surface of an egg to mask the area and keep it the egg's current colour. When the egg is submerged in a dye, the colour of the dye is added to/mixed with the colour of the exposed areas of the egg, but the areas that are covered in wax are unaffected. The process might go as follows: first white areas are masked, then yellow is added, the yellow areas are masked, then blue is added, the now green areas are masked, and finally, red is added causing all of the remaining areas to turn black.
The only issue is that the hot metal tool that is used to melt and apply wax to eggs would probably deform a plastic key and the wax might melt off in a warm bath of dye. However, you could try a mask material that isn't so reliant on heat.
The easiest method I can think of for this would be to mask the area you want to dye with a sticker and paint the area that you don't want to dye with a clear coat. You can buy peel and stick letters, but it might be tricky to get a good font of the right size. You could make your own sticker by printing out the characters you want on paper, applying some double-sided tape to the reverse side (the good stuff with a layer of wax paper attached), and cutting them out with an exacto knife.