Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-24 Thread Dawid Ferenczy
Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:

 Getting that kind of functionality in the Windows console is tricky but
 I think it should be there in the latest snapshot.  I also fixed some
 problems with some of the escape sequences that scroll the screen.
 
 There is still one more difference between Cygwin and, e.g., xterm
 though.  The scroll buffer is still there when you enter a full screen
 session like vim or less.  So you can scroll up to it and really cause
 confusion.  It's possible to fix that behavior but it would be really
 tricky.  I'm not sure I want to complicate the console handling code
 for this one corner case.
 
 The new behavior is in the latest snapshot.
 
 http://cygwin.com/snapshots/
 
 cgf



Hi Christopher,

Thank you very much for your interest. But I have to say, it's now worse 
than it was before. I'm using the latest snapshot (2014-02-24).

My findings:

1. Clear screen (CTRL + L) now works better, it simply scrolls to the end 
of the scrollback buffer and appends to it. But the screen isn't cleared, 
what should be the main purpose of the clear screen :) After clearing of 
screen, current prompt is on the most bottom line of screen with scrollback 
buffer above. I think that it's should be on the first line of screen and 
the screen bellow should be empty. So add of scroll screen_height lines 
down should be enough to resolve this.

2. Scrollback buffer seems to be fine until I use LESS/VIM etc. 
(alternative screen). Than it's messed. Alternative screen shouldn't 
influence the scrollback buffer, I think.

3. It's incompatible with screen (screen manager). Status line of screen is 
overwritten with screen content and when screen content reaches the most 
bottom line of screen, it doesn't scroll, so any additional content is 
hidden.

- - - - - - - - - -

I really don't know much about how that command line related things works 
in Linux, but could it be possible that you work with screen and scrollback 
buffer wrong way? I mean, maybe there are some rules, how to work with 
screen content and buffer, so it would work everywhere (e.g. in the screen 
manager) rather that trying to fix bugs, write workarounds and hacks.

I wonder that nobody else have similar issues, because this is absolutely 
essential, when you work with terminal, I think. I had none of these 
problems, when I was using smaller screen size. Everything started with my 
new laptop with HD display, because I used to have terminal window in 
fullscreen mode.

Thank you for your time and have a nice day.

-- 
 Dawid Ferenczy
 http://ferenczy.cz


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-24 Thread Christopher Faylor
On Mon, Feb 24, 2014 at 05:35:21PM +, Dawid Ferenczy wrote:
Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:

 Getting that kind of functionality in the Windows console is tricky but
 I think it should be there in the latest snapshot.  I also fixed some
 problems with some of the escape sequences that scroll the screen.
 
 There is still one more difference between Cygwin and, e.g., xterm
 though.  The scroll buffer is still there when you enter a full screen
 session like vim or less.  So you can scroll up to it and really cause
 confusion.  It's possible to fix that behavior but it would be really
 tricky.  I'm not sure I want to complicate the console handling code
 for this one corner case.
 
 The new behavior is in the latest snapshot.
 
 http://cygwin.com/snapshots/

Thank you very much for your interest. But I have to say, it's now worse 
than it was before. I'm using the latest snapshot (2014-02-24).

This wasn't my snapshot, it was Corinna's.  I am still working on the
problem.

cgf

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-24 Thread Christopher Faylor
On Mon, Feb 24, 2014 at 12:48:01PM -0500, Christopher Faylor wrote:
On Mon, Feb 24, 2014 at 05:35:21PM +, Dawid Ferenczy wrote:
Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:

 Getting that kind of functionality in the Windows console is tricky but
 I think it should be there in the latest snapshot.  I also fixed some
 problems with some of the escape sequences that scroll the screen.
 
 There is still one more difference between Cygwin and, e.g., xterm
 though.  The scroll buffer is still there when you enter a full screen
 session like vim or less.  So you can scroll up to it and really cause
 confusion.  It's possible to fix that behavior but it would be really
 tricky.  I'm not sure I want to complicate the console handling code
 for this one corner case.
 
 The new behavior is in the latest snapshot.
 
 http://cygwin.com/snapshots/

Thank you very much for your interest. But I have to say, it's now worse 
than it was before. I'm using the latest snapshot (2014-02-24).

This wasn't my snapshot, it was Corinna's.  I am still working on the
problem.

That said, however.  I have checked out the snapshot.

My findings:

1. Clear screen (CTRL + L) now works better, it simply scrolls to the end 
of the scrollback buffer and appends to it. But the screen isn't cleared, 
what should be the main purpose of the clear screen :) After clearing of 
screen, current prompt is on the most bottom line of screen with scrollback 
buffer above. I think that it's should be on the first line of screen and 
the screen bellow should be empty. So add of scroll screen_height lines 
down should be enough to resolve this.

I am aware of how clear screen is supposed to work.  I obviously don't
see this behavior.  I tried this with a cmd window without a scrollback
buffer and with a scrollback buffer at the beginning, middle, and end.

You're going to need to provide details about your console layout.  How
many lines in your buffer?  Where are you when you see this behavior?  In
the middle of the buffer?  Absolute end of the buffer?  Near the end of
the buffer?

I assume you're just using a cmd.exe.  You've probably mentioned if you
are using the 64-bit or 32-bit version but please clarify that again.

2. Scrollback buffer seems to be fine until I use LESS/VIM etc. 
(alternative screen). Than it's messed. Alternative screen shouldn't 
influence the scrollback buffer, I think.

I don't see this.  If you are trying to scroll the screen while in vim
then see my previous observations about this, i.e., don't do that.

3. It's incompatible with screen (screen manager). Status line of screen is 
overwritten with screen content and when screen content reaches the most 
bottom line of screen, it doesn't scroll, so any additional content is 
hidden.

I don't see any problems with screen so you're going to have to provide
details about your setup.  Again, however, if you are trying to use the
scrollback buffer while in screen or any other full-screen utility it
isn't going to work well and it has never worked well.

cgf

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-24 Thread Dawid Ferenczy
Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:

 This wasn't my snapshot, it was Corinna's.  I am still working on the
 problem.
 
 cgf


Oh, I'm sorry, I didn't know that. I wouldn't bother you, I really appreciate 
your support. If you would need a support with anything (e.g. testing), just 
write me (directly to my e-mail).

Thank you and have a nice day.

--
 Dawid Ferenczy
 http://ferenczy.cz


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-24 Thread Christopher Faylor
On Tue, Feb 25, 2014 at 12:16:37AM +, Dawid Ferenczy wrote:
Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:
This wasn't my snapshot, it was Corinna's.  I am still working on the
problem.

Oh, I'm sorry, I didn't know that.  I wouldn't bother you, I really
appreciate your support.  If you would need a support with anything
(e.g.  testing), just write me (directly to my e-mail).

Sorry but that's not how it works.  We use the mailing list for this
type of thing.  You are subscribed so you should be seeing my messages
like this one:

http://cygwin.com/ml/cygwin/2014-02/msg00634.html

cgf

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-23 Thread Andrey Repin
Greetings, Christopher Faylor!

 So, I did go ahead and implement this in Cygwin by switching console
 buffers.  It works great in a cmd window but not at all in a TCMD
 http://jpsoft.com/ window.  I have used jpsoftware products for longer
 than I've been working on Cygwin so that's personally a bad bug for me.

The only other console emulator I know is 
http://code.google.com/p/conemu-maximus5/

 I'm trying to file a bug report but I wonder if this will cause a
 problem for other console programs if it doesn't work for a popular
 commercial product.

Not to break your hope, but I've had very poor experience with their tech
support so far.
(And yes, I'm using their products since 1998, at least.)


--
WBR,
Andrey Repin (anrdae...@yandex.ru) 24.02.2014, 03:24

Sorry for my terrible english...


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-23 Thread Christopher Faylor
On Mon, Feb 24, 2014 at 03:28:53AM +0400, Andrey Repin wrote:
Greetings, Christopher Faylor!

 So, I did go ahead and implement this in Cygwin by switching console
 buffers.  It works great in a cmd window but not at all in a TCMD
 http://jpsoft.com/ window.  I have used jpsoftware products for longer
 than I've been working on Cygwin so that's personally a bad bug for me.

The only other console emulator I know is 
http://code.google.com/p/conemu-maximus5/

There are several more that I'm aware of.

 I'm trying to file a bug report but I wonder if this will cause a
 problem for other console programs if it doesn't work for a popular
 commercial product.

Not to break your hope, but I've had very poor experience with their tech
support so far.
(And yes, I'm using their products since 1998, at least.)

I've had the opposite experience.  I actually got a response to my query.  If
I can find some way of detecting when I'm in a TCMD environment I might just
fall back to the old code.

cgf

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-23 Thread Andrey Repin
Greetings, Christopher Faylor!

 So, I did go ahead and implement this in Cygwin by switching console
 buffers.  It works great in a cmd window but not at all in a TCMD
 http://jpsoft.com/ window.  I have used jpsoftware products for longer
 than I've been working on Cygwin so that's personally a bad bug for me.


 If I can find some way of detecting when I'm in a TCMD environment I might
 just fall back to the old code.

Don't they have a direct API to answer this kind of questions?


--
WBR,
Andrey Repin (anrdae...@yandex.ru) 24.02.2014, 04:41

Sorry for my terrible english...


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-23 Thread Christopher Faylor
On Mon, Feb 24, 2014 at 04:42:25AM +0400, Andrey Repin wrote:
Greetings, Christopher Faylor!
So, I did go ahead and implement this in Cygwin by switching console
buffers.  It works great in a cmd window but not at all in a TCMD
http://jpsoft.com/ window.  I have used jpsoftware products for
longer than I've been working on Cygwin so that's personally a bad bug
for me.


If I can find some way of detecting when I'm in a TCMD environment I
might just fall back to the old code.

Don't they have a direct API to answer this kind of questions?

I sort of asked them that but they haven't replied yet.  Do you know of
something?  I don't see anything pertinent in their documentation.

cgf

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-23 Thread Andrey Repin
Greetings, Christopher Faylor!

So, I did go ahead and implement this in Cygwin by switching console
buffers.  It works great in a cmd window but not at all in a TCMD
http://jpsoft.com/ window.  I have used jpsoftware products for
longer than I've been working on Cygwin so that's personally a bad bug
for me.


If I can find some way of detecting when I'm in a TCMD environment I
might just fall back to the old code.

Don't they have a direct API to answer this kind of questions?

 I sort of asked them that but they haven't replied yet.  Do you know of
 something?  I don't see anything pertinent in their documentation.

Nothing from the top of my head. I've worked with their GUI briefly in the
beginning, then reverted to pure console (4NT back in the days) due to a
number of incompatibilities with existing apps, and never looked back.


--
WBR,
Andrey Repin (anrdae...@yandex.ru) 24.02.2014, 08:33

Sorry for my terrible english...


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-22 Thread Christopher Faylor
On Sun, Feb 16, 2014 at 07:08:01PM -0500, Christopher Faylor wrote:
On Mon, Feb 17, 2014 at 12:46:37AM +0400, Andrey Repin wrote:
Greetings, Christopher Faylor!
 There is still one more difference between Cygwin and, e.g., xterm
 though.  The scroll buffer is still there when you enter a full screen
 session like vim or less.  So you can scroll up to it and really cause
 confusion.  It's possible to fix that behavior but it would be really
 tricky.  I'm not sure I want to complicate the console handling code
 for this one corner case.

I don't have any expertise in trickyness of this task, but I know application,
that does exactly this.
Far manager shrink console output buffer to console window size by default,
when starting up.
The file you're looking for is
http://farmanager.googlecode.com/svn/trunk/unicode_far/console.cpp

I wasn't implying that I don't know how to do it.  It is tricky to get
right for Cygwin.

So, I did go ahead and implement this in Cygwin by switching console
buffers.  It works great in a cmd window but not at all in a TCMD
http://jpsoft.com/ window.  I have used jpsoftware products for longer
than I've been working on Cygwin so that's personally a bad bug for me.

I'm trying to file a bug report but I wonder if this will cause a
problem for other console programs if it doesn't work for a popular
commercial product.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-16 Thread Christopher Faylor
On Wed, Feb 12, 2014 at 01:33:19PM +, Dawid Ferenczy wrote:
I'm working with CLI having long scrollback buffer. I need to read 
something a couple of pages back, so I scroll back in the buffer. Then I 
clear the screen with CTRL + L. Screen is already cleared, but only the 
visible screen in the middle of scrollback buffer. When content fulfills 
the whole screen and it starts to scroll, the new output is mixed with 
previous buffer content. Also scrollback buffer is now messed.

I think, that clearing of the screen with CTRL + L should work as in the 
Linux terminal (e.g. Gnome Terminal). When I press CTRL + L in the middle 
of scrollback buffer, it just jumps to the end of scrollback buffer. 

Getting that kind of functionality in the Windows console is tricky but
I think it should be there in the latest snapshot.  I also fixed some
problems with some of the escape sequences that scroll the screen.

There is still one more difference between Cygwin and, e.g., xterm
though.  The scroll buffer is still there when you enter a full screen
session like vim or less.  So you can scroll up to it and really cause
confusion.  It's possible to fix that behavior but it would be really
tricky.  I'm not sure I want to complicate the console handling code
for this one corner case.

The new behavior is in the latest snapshot.

http://cygwin.com/snapshots/

cgf

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-16 Thread Andrey Repin
Greetings, Christopher Faylor!

 There is still one more difference between Cygwin and, e.g., xterm
 though.  The scroll buffer is still there when you enter a full screen
 session like vim or less.  So you can scroll up to it and really cause
 confusion.  It's possible to fix that behavior but it would be really
 tricky.  I'm not sure I want to complicate the console handling code
 for this one corner case.

I don't have any expertise in trickyness of this task, but I know application,
that does exactly this.
Far manager shrink console output buffer to console window size by default,
when starting up.
The file you're looking for is
http://farmanager.googlecode.com/svn/trunk/unicode_far/console.cpp


--
WBR,
Andrey Repin (anrdae...@yandex.ru) 16.02.2014, 23:50

Sorry for my terrible english...


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-16 Thread Christopher Faylor
On Mon, Feb 17, 2014 at 12:46:37AM +0400, Andrey Repin wrote:
Greetings, Christopher Faylor!
 There is still one more difference between Cygwin and, e.g., xterm
 though.  The scroll buffer is still there when you enter a full screen
 session like vim or less.  So you can scroll up to it and really cause
 confusion.  It's possible to fix that behavior but it would be really
 tricky.  I'm not sure I want to complicate the console handling code
 for this one corner case.

I don't have any expertise in trickyness of this task, but I know application,
that does exactly this.
Far manager shrink console output buffer to console window size by default,
when starting up.
The file you're looking for is
http://farmanager.googlecode.com/svn/trunk/unicode_far/console.cpp

I wasn't implying that I don't know how to do it.  It is tricky to get
right for Cygwin.

cgf

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-16 Thread Andrey Repin
Greetings, Christopher Faylor!

 There is still one more difference between Cygwin and, e.g., xterm
 though.  The scroll buffer is still there when you enter a full screen
 session like vim or less.  So you can scroll up to it and really cause
 confusion.  It's possible to fix that behavior but it would be really
 tricky.  I'm not sure I want to complicate the console handling code
 for this one corner case.

I don't have any expertise in trickyness of this task, but I know application,
that does exactly this.
Far manager shrink console output buffer to console window size by default,
when starting up.
The file you're looking for is
http://farmanager.googlecode.com/svn/trunk/unicode_far/console.cpp

 I wasn't implying that I don't know how to do it.  It is tricky to get
 right for Cygwin.

Ahha, makes sense. Thought that since you are recording console buffer
already, this should be kind of trivial to flip console buffer size back and
forth without loosing content, but I can imagine, what a mess it could become
when additional restrictions apply, been working with NT console myself in the
past. 


--
WBR,
Andrey Repin (anrdae...@yandex.ru) 17.02.2014, 04:23

Sorry for my terrible english...


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-12 Thread Dawid Ferenczy
Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:

 You're apparently not using a snapshot.
 
 cgf


Hi there!

I have discovered one more bug, which seems to be related:

I'm working with CLI having long scrollback buffer. I need to read 
something a couple of pages back, so I scroll back in the buffer. Then I 
clear the screen with CTRL + L. Screen is already cleared, but only the 
visible screen in the middle of scrollback buffer. When content fulfills 
the whole screen and it starts to scroll, the new output is mixed with 
previous buffer content. Also scrollback buffer is now messed.

I think, that clearing of the screen with CTRL + L should work as in the 
Linux terminal (e.g. Gnome Terminal). When I press CTRL + L in the middle 
of scrollback buffer, it just jumps to the end of scrollback buffer. 
Nothing is really deleted. This way, the whole scrollback buffer is 
preserved and screen is also cleared. So, clearing the screen doesn't clear 
anything in the fact. It just scrolls the content up until the whole screen 
is blank and prompt is on the first line.

I think, that these bugs result from different philosophy of working with 
buffer from the Linux terminal.

I could live with that, I just have to clear the screen on the end of 
scrollback buffer only.

But messing of scrollback buffer, when I quit e.g. LESS as I described in 
my previous post, is really pain. The buffer is messed so many times, how 
much prompts are on the current screen. When I scroll one page back, screen 
is repainted with buffer only from bottom to the most bottom prompt (that 
means only few lines could be repainted, for example), where the most 
bottom prompt is repainted too. So I scroll one more page back and it 
repeats, but with another most bottom prompt. Until all prompts on the 
current screen are repainted. Then it starts to scroll properly.

Thank you and have a nice day.

--
 Dawid Ferenczy
 http://ferenczy.cz


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-12 Thread Larry Hall (Cygwin)

On 2/12/2014 8:33 AM, Dawid Ferenczy wrote:

Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:


You're apparently not using a snapshot.

cgf



Hi there!

I have discovered one more bug, which seems to be related:

...

And which snapshot are you using?  http://cygwin.com/snapshots/


--
Larry

_

A: Yes.
 Q: Are you sure?
 A: Because it reverses the logical flow of conversation.
 Q: Why is top posting annoying in email?

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-02-06 Thread Dawid Ferenczy
Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:

 You're apparently not using a snapshot.
 
 cgf


I love you! :)

It's very close to be perfect now. When I scroll by individual lines, it 
works fine. But when I try to scroll by pages, the screen is repainted 
between prompts only. If there are 3 lines between prompts (one prompt on 
bottom of the screen, 3 lines of output above and previous prompt above), 
only that 3 lines and the most bottom prompt are repainted with buffer. So 
one prompt on the bottom is repainted and it repeats with the prompt above. 
If there is no prompt on current screen (e.g. long output), the whole screen 
is repainted. Is it clear from my description?

-- 
 Dawid Ferenczy
 http://ferenczy.cz


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-01-29 Thread Dawid Ferenczy
Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:

 You are not an acknowledged expert in sleep, issues, or me, so your
 opinions are irrelevant.  I don't know why you felt compelled to comment
 on this minor point but your recommendations, understanding of humor, or
 likes are really off-topic for the Cygwin mailing list.


It's nothing important to talk about I think :)

But could I ask you, if you have some spare time (I know that it's stupid 
:) I haven't got any spare time too), could you take a look on preserving 
the whole scrollback buffer, no matters how big it is, please? As I have 
described in my previous post. When I open and exit e.g. the LESS, the 
visible buffer is preserved, but when I scroll up, there is nothing. I have 
scrollback buffer set to the  lines (as it is maximum in the ConEmu).

Thank you very much for your exemplary support!

-- 
 Dawid Ferenczy
 http://ferenczy.cz


 And the fix is almost perfect. It's only almost perfect, because it
 preserves the visible buffer only, not the whole scrollback buffer, which
 could be much more larger, than the window size. I can live with that, but
 could it be possible to preserve the whole scrollback buffer, no
 matters how big it is? I have a window size of 240 * 70 and scrollback
 buffer of 240 *  characters.
 
 So we need to split the buffer to the regions smaller than 16384 
characters
 (to fit buffer in a heap). Maybe it could be possible to get the
 scrollback buffer dimensions instead of the window dimensions and use
 ReadConsoleOutputWrapper in a loop (buffer_width * buffer_height / 16384
 iterations). Moreover, if the window size is bigger than 32768 characters,
 your fix will fail, because you attempt to read a region bigger than
 16384 characters at once, I guess.
 
 But it's interesting that when I have the window size smaller than 16384
 characters (240 * 62), the whole scrollback buffer is preserved, no
 matters how big it is.



--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-01-29 Thread Christopher Faylor
On Wed, Jan 29, 2014 at 05:28:16PM +, Dawid Ferenczy wrote:
But could I ask you, if you have some spare time (I know that it's stupid 
:) I haven't got any spare time too), could you take a look on preserving 
the whole scrollback buffer, no matters how big it is, please? As I have 
described in my previous post. When I open and exit e.g. the LESS, the 
visible buffer is preserved, but when I scroll up, there is nothing. I have 
scrollback buffer set to the  lines (as it is maximum in the ConEmu).

You're apparently not using a snapshot.

cgf

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-01-05 Thread Robert Klemme
On Sat, Jan 4, 2014 at 4:58 AM, Dawid Ferenczy feren...@volny.cz wrote:
 Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:

 Problems like that interfere with my sleep so it's best to get them out
 of the way before I go to bed.

 that's the difference between real programmers and other coders. Real
 programmer can't go to bed, when he has unsolved issue ;)

I do not like that comparison - even jokingly - because it sends a
wrong message. Sometimes it's really better to sleep things over. You
usually notice the next day when you find out that the solution
created new issues of its own. I'm not saying Christopher did in this
case but I would certainly not recommend to resolve all issues before
going to sleep. :-)

Cheers

robert

-- 
remember.guy do |as, often| as.you_can - without end
http://blog.rubybestpractices.com/

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-01-05 Thread Christopher Faylor
On Sun, Jan 05, 2014 at 03:19:03PM +0100, Robert Klemme wrote:
On Sat, Jan 4, 2014 at 4:58 AM, Dawid Ferenczy wrote:
 Christopher Faylor writes:
 Problems like that interfere with my sleep so it's best to get them out
 of the way before I go to bed.

 that's the difference between real programmers and other coders. Real
 programmer can't go to bed, when he has unsolved issue ;)

I do not like that comparison - even jokingly - because it sends a
wrong message. Sometimes it's really better to sleep things over. You
usually notice the next day when you find out that the solution
created new issues of its own. I'm not saying Christopher did in this
case but I would certainly not recommend to resolve all issues before
going to sleep. :-)

You are not an acknowledged expert in sleep, issues, or me, so your
opinions are irrelevant.  I don't know why you felt compelled to comment
on this minor point but your recommendations, understanding of humor, or
likes are really off-topic for the Cygwin mailing list.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-01-03 Thread Dawid Ferenczy
Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:

 Problems like that interfere with my sleep so it's best to get them out
 of the way before I go to bed.  

Hi Christopher,

that's the difference between real programmers and other coders. Real
programmer can't go to bed, when he has unsolved issue ;)


 Could you briefly describe what was the nature of that limitation and 
how did 
 you fixed it, please? (technically, I'm a developer too)
 
 The problem is described here:
 
 http://stackoverflow.com/questions/14699043/replacement-to-systemcolor
 
 in the first Answer.
 
 I found this after noticing the strange behavior of ReadConsoleOutput.


Thank you, I have a point, now. Moreover I have read the diff of your fix.

And the fix is almost perfect. It's only almost perfect, because it
preserves the visible buffer only, not the whole scrollback buffer, which
could be much more larger, than the window size. I can live with that, but
could it be possible to preserve the whole scrollback buffer, no
matters how big it is? I have a window size of 240 * 70 and scrollback
buffer of 240 *  characters.

So we need to split the buffer to the regions smaller than 16384 characters
(to fit buffer in a heap). Maybe it could be possible to get the
scrollback buffer dimensions instead of the window dimensions and use
ReadConsoleOutputWrapper in a loop (buffer_width * buffer_height / 16384
iterations). Moreover, if the window size is bigger than 32768 characters,
your fix will fail, because you attempt to read a region bigger than
16384 characters at once.

But it's interesting that when I have the window size smaller than 16384
characters (240 * 62), the whole scrollback buffer is preserved, no
matters how big it is.

Thank you and have a nice day.

Dawid Ferenczy


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-01-02 Thread Dawid Ferenczy
Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:

 That's because mintty uses entirely Cygwin mechanisms and the console
 uses Windows.  Windows has a limitation which we didn't know about.
 I'll fix this in the next couple of days.
 
 This bug should be fixed in today's snapshot (when it shows up):
 
 http://cygwin.com/snapshots/
 
 It will, of course, be in the next Cygwin release but there is no fixed
 date for when that will be available.



Hi Christopher,

it's fixed for me too! I really appreciate your support. You wrote that 
you'll fix it in couple of days, not in a few hours :) Especially that you 
have done it on New Year's Eve. You have my respect. Thank you! You really 
improved a quality of y life :) (this issue was very annoying for me).

Could you briefly describe what was the nature of that limitation and how did 
you fixed it, please? (technically, I'm a developer too)

Thank you and have happy and successful year 2014!

Dawid Ferenczy


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2014-01-02 Thread Christopher Faylor
On Fri, Jan 03, 2014 at 12:43:10AM +, Dawid Ferenczy wrote:
Christopher Faylor cgf-use-the-mailinglist-please at cygwin.com writes:

 That's because mintty uses entirely Cygwin mechanisms and the console
 uses Windows.  Windows has a limitation which we didn't know about.
 I'll fix this in the next couple of days.
 
 This bug should be fixed in today's snapshot (when it shows up):
 
 http://cygwin.com/snapshots/
 
 It will, of course, be in the next Cygwin release but there is no fixed
 date for when that will be available.



Hi Christopher,

it's fixed for me too! I really appreciate your support. You wrote that 
you'll fix it in couple of days, not in a few hours :) Especially that you 
have done it on New Year's Eve. You have my respect. Thank you! You really 
improved a quality of my life :) (this issue was very annoying for me).

Problems like that interfere with my sleep so it's best to get them out
of the way before I go to bed.  :-)

Could you briefly describe what was the nature of that limitation and how did 
you fixed it, please? (technically, I'm a developer too)

The problem is described here:

http://stackoverflow.com/questions/14699043/replacement-to-systemcolor

in the first Answer.

I found this after noticing the strange behavior of ReadConsoleOutput.

Thank you and have happy and successful year 2014!

You're welcome.

cgf

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2013-12-31 Thread Bengt Larsson
Dawid Ferenczy wrote:
The only difference (or one of few) was in the display size. The old laptop
has a screen resolution of 1366 x 768 pixels, while the new one has
1920 x 1080. And I'm using the whole screen for the terminal window. It's
really strange, but if the terminal window height is greater than
cca 62 lines, the screen buffer is cleared after quitting the LESS, VIM
etc. No matters if Cygwin is executed inside the ConEMu or plain cmd.exe.
Making the terminal window smaller solved the problem. Window height
of 62 lines seems to be fine for me. Also, with some of greater height
values, the LESS/VIM process sometimes crashed.

There does seem to be a problem with the Windows console. I have 64 bit
Windows 7, and when a console window height*width is bigger than about
16384, it starts clearing the window after less. This is running
less from the Windows shell. Not only does it clear the screen, it
clears it to black, even though I have a different background color.

With mintty and bash it works for me at least up to 383 rows and 1364
columns.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2013-12-31 Thread Christopher Faylor
On Tue, Dec 31, 2013 at 10:50:29AM +0100, Bengt Larsson wrote:
Dawid Ferenczy wrote:
The only difference (or one of few) was in the display size. The old laptop
has a screen resolution of 1366 x 768 pixels, while the new one has
1920 x 1080. And I'm using the whole screen for the terminal window. It's
really strange, but if the terminal window height is greater than
cca 62 lines, the screen buffer is cleared after quitting the LESS, VIM
etc. No matters if Cygwin is executed inside the ConEMu or plain cmd.exe.
Making the terminal window smaller solved the problem. Window height
of 62 lines seems to be fine for me. Also, with some of greater height
values, the LESS/VIM process sometimes crashed.

There does seem to be a problem with the Windows console. I have 64 bit
Windows 7, and when a console window height*width is bigger than about
16384, it starts clearing the window after less. This is running
less from the Windows shell. Not only does it clear the screen, it
clears it to black, even though I have a different background color.

With mintty and bash it works for me at least up to 383 rows and 1364
columns.

That's because mintty uses entirely Cygwin mechanisms and the console
uses Windows.  Windows has a limitation which we didn't know about.
I'll fix this in the next couple of days.

cgf

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2013-12-31 Thread Christopher Faylor
On Tue, Dec 31, 2013 at 01:58:59PM -0500, Christopher Faylor wrote:
On Tue, Dec 31, 2013 at 10:50:29AM +0100, Bengt Larsson wrote:
Dawid Ferenczy wrote:
The only difference (or one of few) was in the display size. The old laptop
has a screen resolution of 1366 x 768 pixels, while the new one has
1920 x 1080. And I'm using the whole screen for the terminal window. It's
really strange, but if the terminal window height is greater than
cca 62 lines, the screen buffer is cleared after quitting the LESS, VIM
etc. No matters if Cygwin is executed inside the ConEMu or plain cmd.exe.
Making the terminal window smaller solved the problem. Window height
of 62 lines seems to be fine for me. Also, with some of greater height
values, the LESS/VIM process sometimes crashed.

There does seem to be a problem with the Windows console. I have 64 bit
Windows 7, and when a console window height*width is bigger than about
16384, it starts clearing the window after less. This is running
less from the Windows shell. Not only does it clear the screen, it
clears it to black, even though I have a different background color.

With mintty and bash it works for me at least up to 383 rows and 1364
columns.

That's because mintty uses entirely Cygwin mechanisms and the console
uses Windows.  Windows has a limitation which we didn't know about.
I'll fix this in the next couple of days.

This bug should be fixed in today's snapshot (when it shows up):

http://cygwin.com/snapshots/

It will, of course, be in the next Cygwin release but there is no fixed
date for when that will be available.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2013-12-31 Thread Balaji Venkataraman
On Tue, Dec 31, 2013 at 2:29 PM, Christopher Faylor wrote:

 This bug should be fixed in today's snapshot (when it shows up):

 http://cygwin.com/snapshots/

I was seeing the same problem when using mintty (inside ConEmu).
This seems to fix the problem. Thanks.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2013-12-31 Thread Bengt Larsson
Christopher Faylor wrote:

This bug should be fixed in today's snapshot (when it shows up):

http://cygwin.com/snapshots/

Works fine now.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2013-12-31 Thread Christopher Faylor
On Tue, Dec 31, 2013 at 02:58:12PM -0800, Balaji Venkataraman wrote:
On Tue, Dec 31, 2013 at 2:29 PM, Christopher Faylor wrote:

 This bug should be fixed in today's snapshot (when it shows up):

 http://cygwin.com/snapshots/

I was seeing the same problem when using mintty (inside ConEmu).
This seems to fix the problem. Thanks.

I don't understand how you could use mintty within conemu but thanks
for the confirmation.

cgf

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2013-12-31 Thread Balaji Venkataraman
On Tue, Dec 31, 2013 at 8:03 PM, Christopher Faylor wrote:

 I don't understand how you could use mintty within conemu but thanks
 for the confirmation.

Not sure if this is what you meant to ask but all I have is a ConEmu
task like this: C:\cygwin\bin\mintty.exe C:\cygwin\bin\bash.exe
--login -i -new_console:t:cygwin32 (without the quotes).

I was forced to go this route because I was unwilling to abandon
ConEmu and cannot do without Cygwin or GNU screen and there was no way
screen would re-attach outside of mintty.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2013-12-31 Thread Christopher Faylor
On Tue, Dec 31, 2013 at 11:00:45PM -0800, Balaji Venkataraman wrote:
On Tue, Dec 31, 2013 at 8:03 PM, Christopher Faylor wrote:

 I don't understand how you could use mintty within conemu but thanks
 for the confirmation.

Not sure if this is what you meant to ask but all I have is a ConEmu
task like this: C:\cygwin\bin\mintty.exe C:\cygwin\bin\bash.exe
--login -i -new_console:t:cygwin32 (without the quotes).

I was forced to go this route because I was unwilling to abandon
ConEmu and cannot do without Cygwin or GNU screen and there was no way
screen would re-attach outside of mintty.

Ah, I see.  I should have actually read the ConEmu project page rather
than assuming that I knew what it did.  Thanks for clarifying.

cgf

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Clearing the buffer after quitting LESS, MAN, VIM etc.

2013-12-30 Thread Dawid Ferenczy
Dawid Ferenczy ferenczy at volny.cz writes:

 Hi,
 
 maybe I have found a bug in the Cygwin.



Hi again,

I forgot to mention some essential data :)

I'm using the 64bit version of Cygwin on the 64bit Windows 7 Home Premium, 
cygwin1.dll version is 1.7.27, setup.exe version is 2.831.

The issue appears under the ConEmu terminal emulator and also under the 
plain cmd.exe.

Dawid Ferenczy



--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple