Can SE add an option to fix the height of the edit-preview DIV? It currently makes the page grow very long with large code blocks. It would be useful if there is a checkbox that will toggle between
- current auto-sized faithful preview; and
- sizable DIV with a handle just like the edit textarea
This will make it easier to work with editing in split top/bottom screen mode seeing both at the same time. As it stands, it is impossible to see the full preview of long posts without scrolling to the bottom each time.
Here's a case in point - MySQL query - possible to include this clause? - please try editing it and at the same time attempt to maintain coherency between edit/preview, but please, don't make any changes :)
Possibly related to
- Question and preview might be better side-by-side
- Could the change from an edit be displayed in a side-by-side display
EDIT
Never considered this, but popular demand raises an interesting point about not-so-enlightened users.
It's another option that will increase confusion, especially when people switch it on expecting their posts to remain in fancy scrollable boxes after they hit "post."
I think it would work nicely as a privilege... if only to separate users who will use this sensibly (and thank SE each time they do), and those lower-rep/near-anonymous users who may remotely get confused.
-
Frankly I don't see why it needs to be an option. Just have it like that when you edit - the bit you see in the preview is centered around the bit you are currently editing. Nothing else makes sense. Don't make it an option and don't confuse people.Floris– Floris2014年10月07日 11:31:54 +00:00Commented Oct 7, 2014 at 11:31
-
This would be very useful for long answers or questions, and even for shorter ones that include images. I've posted a feature request to have side-by-side preview with autoscroll, the same way Discourse has.Dan Dascalescu– Dan Dascalescu2015年04月09日 22:26:43 +00:00Commented Apr 9, 2015 at 22:26
2 Answers 2
Agreed. For long answers, this can be a major PITA, and it's so simple to implement - a single CSS rule:
#wmd-preview.not-too-tall {
max-height: 200px; /* same as the default height of the answer textarea */
overflow-y: auto;
}
and a checkbox somewhere on the page to toggle it:
$('#some-checkbox-id').change(function ()
{
$('#wmd-preview').toggleClass('not-too-tall', this.checked);
});
After further thought, I think this would best be implemented as a user pref. People who want it will probably just be aggravated by having to check a box every bleedin' time they ask a question, write an answer, or edit anything. People who don't want it won't be bothered by it.
-
Or we could implement side-by-side Markdown preview the same way Discourse does.Dan Dascalescu– Dan Dascalescu2015年04月09日 22:25:15 +00:00Commented Apr 9, 2015 at 22:25
I'm not a fan of this. It's another option that will increase confusion, especially when people switch it on expecting their posts to remain in fancy scrollable boxes after they hit "post."
-
I'd hate for avid SO users to make that sort of assumption. Good point about first time users. Maybe earn it as a privilege.RichardTheKiwi– RichardTheKiwi2011年01月27日 02:29:51 +00:00Commented Jan 27, 2011 at 2:29
-
@cyber: TBH, that sounds like a bad candidate for a rep-based privilege.Matt Ball– Matt Ball2011年01月27日 03:06:49 +00:00Commented Jan 27, 2011 at 3:06
-
Just a suggestion if anyone is in PD's boat being concerned about users (programmers?!) getting
confusedby such a checkboxRichardTheKiwi– RichardTheKiwi2011年01月27日 03:08:24 +00:00Commented Jan 27, 2011 at 3:08 -
@cyber, there are plenty of non-technical types using Stack Exchange these days. Not that programmers are perfect; for examples of programmers failing to use the Stack Exchange interface, please see
meta.stackoverflow.comPops– Pops2011年01月27日 15:10:06 +00:00Commented Jan 27, 2011 at 15:10