![]() Select all your text and then expand the styles gallery on the home tab of the ribbon.In Word, hit Ctrl+Alt+V and choose HTML Format to paste the coloured text.Copy the required code (HTML colourising info will be copied with it).Temporarily set your IDE's theme to a light one, so that the text will fit in with the rest of your document.This solution is entirely self-contained in Word, works across multiple pages, and keeps your syntax highlighting. So I've found the majority of answers on this question to either be only semi-functional or broken entirely (eg the website used is down). In the newly created " Code_numberline" add the numbering style that you like (this will automate line numbering).Īpply " Code_numberline" to the first column, and " Code" to the 3 column. ( You will have to get in " Table Properties" for fine tuning).Ĭreate a " Paragraph Style" with the name of " Code" just for your code snippets ( check to get the idea, you don't have to follow all of it)Ĭreate another " Paragraph Style" with the name of " Code_numberline" that will be based upon the previous created style. Make the adjustments to cells' spacing and columns' width to get the aspect you like. ![]() it should have this aspect.īe ware that those lines are for you to see the table's grid, and the will not be printed. Use invisible borders (" No Borders" option), and activate " View Gridlines" option. Insert a 3x3 table, in my case I always make the total width of the table equals the free page's width ( 3 rows minimum to test the tables style). It will not maintain code colouring although someone could improve my trick.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |