No matter how much we discourage it, posters frequently write questions with all the code in an image that they link to. I personally don't think this should be a reason to close the questions -- if the image is inline, the question is usually quite understandable, it's just more of a PITA to answer since you can't copy the code to test or modify it. So I post a comment asking them to post it as plain text, but then I inline the image anyway to make the question readable.
I think the only way we'll get people not to post these links is if we outright prohibit it. So if you have too little rep, you wouldn't be allowed to post links to images at all. That will force them to paste the text.
I understand that sometimes images are useful when used in addition to the code, e.g. for screenshots of the resulting page. Perhaps it could be similar to the jsfiddle/codepen restriction: you can only post these links if you also post code. Sometimes people will get around the restriction by posting a tiny code block with all the real code in the image, but it should still be an improvement.
algorithm
tag. Enforcing code in those doesn't make sense.