no, heat can't do that. it looks like mechanical damage to me, like you had it pinched between the pot and the wall, or the pot next to it.
gnats don't eat your plants, they're harmless once they're flying. the problem with gnats is that the maggots eat roots. if you get them bad enough, they can seriously damage your root system, but they'll never eat a leaf.
ipc is integrated pest control. get some insect frass, and some silica, and use both when you water. the silica makes thicker cell walls that are harder for the bugs to penetrate, and the insect frass triggers the plants own immune system, like giving them an insect vacination.