|
Which conversation?
(But I'll look into the countr thing)
cheers,
Chris Maunder
CodeProject.com : C++ MVP
|
|
|
|
|
The messages for that article are gone, you seem to have removed them; the article is now at version 3, it was version 1 when I posted.
The dialogue went something like:
"Are you really from Afghanistan?"
"What do you mean?"
"With a name like that?"
"Oh, I see what you mean. Fixed it."
|
|
|
|
|
Found the issue. Thanks!
cheers,
Chris Maunder
CodeProject.com : C++ MVP
|
|
|
|
|
You're welcome.
Luc Pattyn [Forum Guidelines] [My Articles]
- before you ask a question here, search CodeProject, then Google
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get
- use the code block button (PRE tags) to preserve formatting when showing multi-line code snippets
|
|
|
|
|
Hi Chris,
when copying a code snippet from Visual Studio to a message editing box on CP,
my tabs (set to 4 in Visual) grow to 8, and larger snippets[^] tend to become too wide for comfort.
Is it at all possible to make both the editing and the viewing of forum messages use a smaller
tab width, in my very subjective opinion 4 would be ideal.
I do not want you to automatically untabify pasted text, and I do know I could have untabified
my snippet first, and I did read PIEBALDs recent article on the subject, but I want it to remain easy...
If the above is technically impossible, then I might be in favor of one more checkbox ("untabify by 4 while pasting") in the message editing page.
[ADDED]Another example[^], possibly less exemplary[/ADDED]
modified on Tuesday, January 20, 2009 12:17 PM
|
|
|
|
|
Welcome to HTML standards[^].
8 spaces. It's ridiculous.
My options:
1. Replace every tab with
This will mean pasting it into VS will lose tabs (though keep spaces)
2. Replace a tab with <span style='display:none'>[Tab character]</span><span style='margin-left:4em'></span>
This will allow tabs to be preserved at the expense of a bigger HTML download payload
cheers,
Chris Maunder
CodeProject.com : C++ MVP
|
|
|
|
|
Hi Chris,
I experimented a bit with this:
a sp3
a nbsp3
a sp7
a nbsp7
a tab
a<span style="display:none"> </span><span style="margin-left:4em"></span>span4
ab sp2
ab nbsp2
ab sp6
ab nbsp6
ab tab
ab<span style="display:none"> </span><span style="margin-left:4em"></span>span4
ab<span style="display:none"> </span><span style="margin-left:3em"></span>span3
where spN is N regular spaces, nbspN is N non-breaking spaces, tab is a HTAB character,
spanN is a span entity with left margin N em
looking at it with FF3 and IE7, and pasting to VS2008.
observations:
- regular spaces and non-breaking spaces work identical inside PRE tags.
- tab width is not correct (too narrow), it does not match 8 spaces (both IE7 and FF3)
- 4em span width is correct on IE7, not on FF3, when 3 or 7 spaces would be required;
- 4em and 3em span width are not correct when 2 or 6 spaces would be required.
- copy-paste to Visual Studio works as expected (result is spaces or tabs)
conclusion:
- it is a mess; there seems to be no way to get it right for 2 popular browsers
- if anything needs changing, it is the browsers: they could offer a switch to set the
tab width to 8 (HTML standard) or less (4 or 2) at the user's discretion. I doubt it
they would even consider that if not specified in the HTML spec though.
- just keep tab handling at CP the way it is; there is no easy way to make it really better.
Thanks.
|
|
|
|
|
1em is the width of a (you guessed it!) M, which is different than the width of a space.
We used to change it so that tabs were converted to but this caused some gnashing of teeth.
I do wish the W3C would rush out tab-width as a standard.
cheers,
Chris Maunder
CodeProject.com : C++ MVP
|
|
|
|
|
Hi Chris,
all my experiments got executed inside PRE tags, i.e. with non-proportional or monospaced fonts,
so I would expect an em, a 'M' and a space to all have exactly the same width
Luc Pattyn [Forum Guidelines] [My Articles]
- before you ask a question here, search CodeProject, then Google
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get
- use the code block button (PRE tags) to preserve formatting when showing multi-line code snippets
|
|
|
|
|
Personally I'm ready to slap the W3C
cheers,
Chris Maunder
CodeProject.com : C++ MVP
|
|
|
|
|
I so see that there is not a simple solution. The ideal solution would be to get the standard revised, but that will take years.
A possible compromise would be to use (or something like that) one time when there is an odd number of tabs and not at all when there is an even number of tabs; use tabs to replace each two tabs otherwise. That will make copying to elsewhere incorrect, but that might be acceptable. You might possibly have a simple script that does the necessary conversion.
|
|
|
|
|
Remember way back in 2000 or 2001 when that guy posted an article about the Quran? Is there any hope of retrieving that article, or is it just plain gone? That article resulted in one of the funniest threads I've ever seen here (of which I played a big part, of course).
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
I remember that one fondly. Unfortunately it's gone to a better place.
cheers,
Chris Maunder
CodeProject.com : C++ MVP
|
|
|
|
|
Double-damn!
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
When I search messages in a forum, despite the fact that it returns multiple pages of results, when I try to go to a subsequent page of those results, I get the page that claims no search results were found.
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
What search term and search settings? I've not been able to replicate
cheers,
Chris Maunder
CodeProject.com : C++ MVP
|
|
|
|
|
Pretty much anything I tried. I specified a word to search for, and a date range. Sometimes, I'd get an indication of as many as 10 pages of results , but when I clicked "Next", or the "2" (or any other of the listed pages), I would get a page that said no search results were found. If I clicked "1" or the browser's Back button, I'd get the first page of results.
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
I can't (of course!) replicate what you're seeing but I did find another issue with the date ranges not being preserved. Will fix that.
cheers,
Chris Maunder
CodeProject.com : C++ MVP
|
|
|
|
|
After editing, blah blah...
Just thought my might want to know.
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
I haven't forgotten nor assumed it's gone away. It's Bug #1351
cheers,
Chris Maunder
CodeProject.com : C++ MVP
|
|
|
|
|
Ahhh, I didn't know if you guys had tried fixing it yet or not. I'll stop reporting it until we hear from you.
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
I suggest that we rename this forum to the "John Simmons gripes and moans" forum.
|
|
|
|
|
removing all the spaces in the code "& lt; p& gt;" yields <p> instead of "< p>" (without the space).
|
|
|
|
|
Fixed next rev. Thanks for that.
cheers,
Chris Maunder
CodeProject.com : C++ MVP
|
|
|
|
|
Chris Maunder wrote: Fixed next rev
a provisional then,
|
|
|
|