Click here to Skip to main content
15,901,001 members
Home / Discussions / .NET (Core and Framework)
   

.NET (Core and Framework)

 
GeneralRe: General threading question Pin
Luc Pattyn14-Sep-10 13:47
sitebuilderLuc Pattyn14-Sep-10 13:47 
GeneralRe: General threading question Pin
The Man from U.N.C.L.E.14-Sep-10 22:28
The Man from U.N.C.L.E.14-Sep-10 22:28 
AnswerRe: General threading question Pin
Ennis Ray Lynch, Jr.15-Sep-10 4:20
Ennis Ray Lynch, Jr.15-Sep-10 4:20 
GeneralRe: General threading question Pin
Ray Cassick15-Sep-10 5:19
Ray Cassick15-Sep-10 5:19 
QuestionLoading of the image from a TIFF-file compressed by a JPEG algorithm Pin
Degun14-Sep-10 3:35
Degun14-Sep-10 3:35 
AnswerRe: Loading of the image from a TIFF-file compressed by a JPEG algorithm Pin
Dave Kreskowiak14-Sep-10 4:07
mveDave Kreskowiak14-Sep-10 4:07 
QuestionProblems with embed windows media player in VB.net form Pin
ocabrera7013-Sep-10 14:11
ocabrera7013-Sep-10 14:11 
QuestionTheory and practice of XML layout? Pin
Gregory Gadow13-Sep-10 10:39
Gregory Gadow13-Sep-10 10:39 
For a side project I am working on, I want to write a layout engine for a very simplified, light-weight mark-up language that will be used for writing hypernovels, also known as interactive fiction (read a page, click on one of the links on the page, and follow the story depending on where the link leads.) For flexibility, I would rather try and write my own engine rather than rely on HTML or XSL transformation.

The mark-up of the page text has <p>, <strong>, <em> and <hr/> tags, which work just like HTML. I am also adding a <high> (highlight) tag which will normally underline text, and a <link> tag to replace the HTML <a> tag (to avoid confusion over very different attributes.) Right now, I am only interested in finding a technique for doing the layout, but eventually the reader will be able to set preferences such as font family, font size and color.

The approach I am working on now is to parse the text into blocks with various rendering styles, use DrawString to write the blocks onto a custom control out one by one, then make a note as to the location of where the last block ended to be the starting location of the next block. The pages would be pre-validated before the book file is created, so I don't need to worry about missing or misaligned tags.

I have tracked down some open source materials, such as the Gecko engine used in Firefox. Unfortunately, the source code has all been complete browser implementations, and I don't really have the time to go through and try to separate the layout engine from JavaScript support, managing plug-ins and gracefully handling cantankerous web servers that have been running for 20 years. What can I say, I'm lazy like that.

Any suggestions as to technique, books, web sites, etc. that present the theory and practice of laying out and rendering marked-up text would be much appreciated. I have a strong preference for VB.Net or C# code, but anything that I can translate into .Net will be welcome, as would materials discussing the theory without the practice.
AnswerRe: Theory and practice of XML layout? Pin
PIEBALDconsult13-Sep-10 17:39
mvePIEBALDconsult13-Sep-10 17:39 
GeneralRe: Theory and practice of XML layout? Pin
Gregory Gadow14-Sep-10 5:06
Gregory Gadow14-Sep-10 5:06 
AnswerRe: Theory and practice of XML layout? Pin
Luc Pattyn14-Sep-10 5:17
sitebuilderLuc Pattyn14-Sep-10 5:17 
GeneralRe: Theory and practice of XML layout? Pin
Gregory Gadow15-Sep-10 3:50
Gregory Gadow15-Sep-10 3:50 
GeneralRe: Theory and practice of XML layout? Pin
Luc Pattyn15-Sep-10 5:41
sitebuilderLuc Pattyn15-Sep-10 5:41 
GeneralRe: Theory and practice of XML layout? Pin
Gregory Gadow15-Sep-10 6:02
Gregory Gadow15-Sep-10 6:02 
GeneralRe: Theory and practice of XML layout? Pin
PIEBALDconsult14-Sep-10 17:59
mvePIEBALDconsult14-Sep-10 17:59 
GeneralRe: Theory and practice of XML layout? Pin
Gregory Gadow15-Sep-10 3:46
Gregory Gadow15-Sep-10 3:46 
GeneralRe: Theory and practice of XML layout? Pin
PIEBALDconsult15-Sep-10 15:54
mvePIEBALDconsult15-Sep-10 15:54 
GeneralYou can't assign to an array element within a For Each loop! [modified] Pin
Peter R. Fletcher13-Sep-10 5:17
Peter R. Fletcher13-Sep-10 5:17 
GeneralRe: You can't assign to an array element within a For Each loop! Pin
Luc Pattyn13-Sep-10 6:13
sitebuilderLuc Pattyn13-Sep-10 6:13 
GeneralRe: You can't assign to an array element within a For Each loop! Pin
Peter R. Fletcher13-Sep-10 8:23
Peter R. Fletcher13-Sep-10 8:23 
GeneralRe: You can't assign to an array element within a For Each loop! Pin
Luc Pattyn13-Sep-10 8:33
sitebuilderLuc Pattyn13-Sep-10 8:33 
GeneralRe: You can't assign to an array element within a For Each loop! Pin
Peter R. Fletcher13-Sep-10 9:24
Peter R. Fletcher13-Sep-10 9:24 
GeneralRe: You can't assign to an array element within a For Each loop! Pin
Luc Pattyn13-Sep-10 9:28
sitebuilderLuc Pattyn13-Sep-10 9:28 
GeneralRe: You can't assign to an array element within a For Each loop! [modified] Pin
harold aptroot13-Sep-10 11:18
harold aptroot13-Sep-10 11:18 
GeneralRe: You can't assign to an array element within a For Each loop! Pin
Luc Pattyn13-Sep-10 11:25
sitebuilderLuc Pattyn13-Sep-10 11:25 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.