It is possible to use Markdown for both the image and the link.
You have to do it manually because the the toolbar's default behavior
is to make the clickable image point to the URL of the image itself.
Reference-style
[![alt text][image]][hyperlink]
[hyperlink]: https://meta.stackoverflow.com/users/44330/jason-s
[image]:
https://www.gravatar.com/avatar/dd5a7ef1476fb01998a215b1642dfd07
(tooltip)
– or –
[image]:
https://www.gravatar.com/avatar/dd5a7ef1476fb01998a215b1642dfd07
"tooltip"
Example
Default behavior, reference-style
Since July 2015 the insert
image feature (Ctrl + G) of the toolbar of the
Stack Exchange Markdown editor by default adds a clickable link to the
image itself.
1
It uses the following syntax:
[![enter image description here][number]][number]
where number
is an automatically generated number.
Default example, reference-style
[![Jason's avatar][1]][1]
[1]: https://i.sstatic.net/X14m7.png
"Tooltip for Jason's avatar"
To change the link to something else, simply change the second
[number]
with (*your URL here*)
(in parentheses) or use the
reference style syntax above.
Inline-style
[![alt text](image "tooltip")](hyperlink)
for example:
[![invisible description of images, read aloud to blind users
](https://i.sstatic.net/X14m7.png
"Let's check Jason S' profile page (inline-style)")
](https://meta.stackoverflow.com/users/44330/jason-s)
Default behavior, inline-style
You can get the default behavior without using the [number]
construct.
[![A click on the image links to its own URL.](
https://i.sstatic.net/X14m7.png
"A click on the image links to its own URL (inline-style).")
](https://i.sstatic.net/X14m7.png)
The observant reader will notice that to achieve the inline-style
default behavior, the URL to the image must be supplied twice.
The first link is there to display the image, the second link
makes the image clickable.
References:
1 The previous default behavior was to just display the
image - without any link at all. ~ * ~ Even the new default behavior
does not add any tooltip for you. – If you want a tooltip, you have to
add it yourself.