code: protected boolean drawImage(Graphics2D g)
      {
          int ofs = getFirstInlineBoxBaseline();
          if (ofs == -1)
              ofs = ctx.getBaselineOffset(); //use the font baseline
          int x = (int) Math.round(getAbsoluteContentX() - 0.5 * ctx.getEm());
          int y = getAbsoluteContentY() + ofs;
          Image img = image.getImage();
          if (img != null)
          {
              int w = img.getWidth(image);
              int h = img.getHeight(image);
              g.drawImage(img, x - w, y - h, image);
              return true;
          }
          else
              return false; //could not decode the image
      }
docs: Draws an image marker