

combine ( getDataDir (), "document.md" ) // Prepare a path for converted file saving Prepare a path to a source Markdown file If your scenario is required rendering Markdown document, for instance, to PNG file format, the following example demonstrates how that is simple: The method takes as parameters document, options, and savePath and performs the conversion. Use the сonvertHTML(document, options, savePath) method of theĬlass to save an intermediate HTML document as a PNG image.ImageFormat.Png will be used as default image format. Use the convertMarkdown(sourcePath) method to convert Markdown to HTML document.Prepare paths for a source Markdown file - sourcePath and converted file saving - savePath.You can convert Markdown to Image in your Java application literally with a few lines of code! Markdown to PNGĬlass are primarily used as the easiest way to convert a Markdown file into various formats. If your scenario is required rendering Markdown document, for instance, to the Image file format, the following example demonstrates how that is simple. Just set the ImageFormat to ImageSaveOptions! You can easily use Java examples to convert Markdown to images, detailed here for converting Markdown to PNG, JPG, BMP, GIF, and TIFF. In this article, you will find information on how to convert a MD to Image using Aspose.HTML for Java and how to apply

You can set the image format to JPG, PNG, BMP, GIF, or TIFF. The ImageSaveOptions(format) constructor initializes the options object with the format specifying. The only difference is in specifying the output image format using theĬlass.
