Isn't a plain text renderer as simple as "concatenate all the sentence structures in order" (pseudocode, I know)? Something like a tree traversal + StringBuilder or the non-.NET equivalent of it? So couldn't you write one based on the sentence object definition you are obviously already using? And wouldn't the large complexity difference be a reason that NLP oriented frameworks only seem to do parsing? (Please feel free to tell me off for not getting the question if you think this is approriate...)
- Jarno Peschier
So this isn't a TrimEnd issue at all, but a problem related to string/character constant use in source code. Perhaps you could edit to change the title of the question to reflect this?
- Jarno Peschier
I agree with awe: for small scale reuse inside a method (or even a class) this is perfect. Like the string.Format examples. I use this quite often. It's basically the same thing as using a local variable for an intermediate value that you use more than once, but for code. Your second example seems to be pushing it a bit. Somehow this gives me the feeling a private method AddSurfaceData (possibly static?) would be a better a fit. That is of course outside of the context that you have, so use your own good judgement.
- Jarno Peschier
Zag afgelopen week dat er al een bouwweg ten zuiden van Station Vleuten geasfalteerd is en dat er al funderingen gebouwd zijn. Ik ben er net even langsgereden met GPS van mijn telefoon aan om dit stukje in kaart te brengen. Daarna heb ik ook eindelijk de busbaan bij het station ook maar ingetekend en de aanleg van het viaduct in de Huis te Vleutenbaan ten behoeve van Het Lint.
- Jarno Peschier
That forces you to write a file somewhere that you need permission for, need to find a location and a name for and mustn't forget to delete when you're done with it. Easier to use RedirectStandardOutput actually.
- Jarno Peschier
This looks different than the problem that was reported to me (prompting my original question). Am almost certain no textboxes were overlapping, but within one Textbox all the characters that made up its contents where overlapping, as if all individually rendered left-aligned in the box.
- Jarno Peschier
Not at all: you can create a list of lists of sieve approximations, and take "as much as you need". You'll need lazy evaluation of course, like in a functional language. I have written an implementation of this in C# using yield statements which as far as I know worked fine. Don't have laptop with me, so I'd have to get back to this later to post the actual answer. (If you all want.)
- Jarno Peschier
Ah, you already mentioned the guides. Here is the URL that I mentioned in my answer (which I have since removed again). +1 blogs.msdn.com/saraford/archive/…
- Jarno Peschier
I agree with FxCop and most of the other answer here: don't catch System.Exception ever, unless it is at the highest level in your application to log unexpected (and thus fatal) exceptions. Also check out this question that's basically about the same thing.
- Jarno Peschier
When you use a VisualStudio .NET setup project, the setup.exe part of the output does not really change when you compile. The real result of the setup project is the MSI file; this is your actual setup. The setup.exe is "just" there to make sure that (the correct version of) Microsoft Installer is installed on the machine before the MSI is executed by Microsoft Installer. So the properties of setup.exe will not change at all, except perhaps with another version of Visual Studio (or a Service Pack), no matter what you change in your setup project or how often your rebuild that setup project.
- Jarno Peschier
@RCIX: Then do that kind of quick throw-away stuff in a script language that is inherently dynamic. I'd rather have strict type safety - but with generics and a smart compiler with type inference like in most functional languages - in the language(s) that I use.
- Jarno Peschier
I find it strange that you leave the login window hidden after the initial login. Why not close it? Then you would not have your current problem: after successful login you only have the main MDI window that when is closed exits the running Windows Forms application. Is there a reason you hide the login window instead of closing it?
- Jarno Peschier
Wouldn't it be better to override OnPaintBackground in this case? (Or am I then mixing up the regular and the compact framework again?)
- Jarno Peschier
And even worse: windows desktop GUI apps (and even installers: Garmin: I'm pointing at you here) seem to be getting into the Mystery Meat business. GUI guidelines are here for a reason!
- Jarno Peschier
This wouldn't work (for this question; in general it sounds fine for the US), as the question already states that a solution that only works for US addresses would not be an acceptable solution.
- Jarno Peschier
As there is a .NET tag on this question, I would simply use System.IO.FileSystemWatcher that's in the .NET Framework. I'm guessing it is implemented using the I/O Filters that Andrew mentions in his answer, but I really do not know (nor care, exactly). Would that fit your needs?
- Jarno Peschier
In this article about IE8 tab grouping it seems you can turn off tab grouping altogether under Tab Options. No option to change the colors or just turn these colors off (second one seems obvious: how would the groups make any sense when you can't see them), but turning off the tab grouping feature entirely might remove the colors?
- Jarno Peschier
Nice answer, and potentially useful, but not really an answer to the posed question. Thought about a -1, but leaving it at this comment. ;-)
- Jarno Peschier