From: Andy Parkins <hidden> Date: 2016-06-15 22:42:53
The log window and changed files list would start at equal sizes. This
patch gives them each a horizontal stretch factor making them have a 3:1
ratio.
The font for the log viewer is set to "Monospace", but this should
really be done in software and given a config setting (perhaps use the
patch view font)
Signed-off-by: Andy Parkins <redacted>
---
src/revsview.ui | 31 ++++++++++++++++++++++++++-----
1 files changed, 26 insertions(+), 5 deletions(-)
From: Marco Costalba <hidden> Date: 2016-06-15 22:42:53
The font for the log viewer is set to "Monospace", but this should
really be done in software and given a config setting (perhaps use the
patch view font)
Thanks Andy for patches, I will apply as soon as I have access to my
box, probably this evening.
Regarding "Monospace" it should be changeable with Settings menu and
should apply _only_ to fixed space font viewers, in our case only
patch viewer and file content viewer.
Other fonts used in qgit are derived from system wide settings and are
changeable with qtconfig tool.
If you see Monospace applied to list view or any other widget apart
from the above mentioned ones then it's a bug.
Thanks
Marco
From: Jakub Narebski <hidden> Date: 2016-06-15 22:42:53
Marco Costalba wrote:
quoted
The font for the log viewer is set to "Monospace", but this should
really be done in software and given a config setting (perhaps use the
patch view font)
Thanks Andy for patches, I will apply as soon as I have access to my
box, probably this evening.
Regarding "Monospace" it should be changeable with Settings menu and
should apply _only_ to fixed space font viewers, in our case only
patch viewer and file content viewer.
Shouldn't commit message be also in fixed-width (monospace) font?
Sometimes there is ASCII-art used (mainly for diagrams) in commit
messages; gitweb uses monospace font for commit messages.
--
Jakub Narebski
Warsaw, Poland
ShadeHawk on #git
From: Andy Parkins <hidden> Date: 2016-06-15 22:42:53
On Thursday 2007 February 08 08:39, Marco Costalba wrote:
Regarding "Monospace" it should be changeable with Settings menu and
should apply _only_ to fixed space font viewers, in our case only
patch viewer and file content viewer.
The log message was the one I changed. Having the log message in variable
width breaks any ascii-art in the message.
I completely agree about pulling the setting from the config. I'll see if I
can find that and post a further patch.
If you see Monospace applied to list view or any other widget apart
from the above mentioned ones then it's a bug.
True. I used "Monospaced" as the font as that defaults to the system-wide
monospaced font; however it's pretty poor form. I raise my hand - shoot
me :-) As I say, I'll try and do better and send a new patch.
Andy
--
Dr Andy Parkins, M Eng (hons), MIEE
andyparkins@gmail.com
From: Andy Parkins <hidden> Date: 2016-06-15 22:42:53
On Thursday 2007 February 08 08:39, Marco Costalba wrote:
Regarding "Monospace" it should be changeable with Settings menu and
should apply _only_ to fixed space font viewers, in our case only
patch viewer and file content viewer.
Incidentally, regarding monospaced fonts and Qt. While developing these
patches I noticed that Qt::convertFromPlainText() swallows leading white
space from the lines. I dropped it and used a style sheet to set the font
instead; but in case you use it elsewhere I thought you might be interested.
Andy
--
Dr Andy Parkins, M Eng (hons), MIEE
andyparkins@gmail.com
From: Marco Costalba <hidden> Date: 2016-06-15 22:42:53
On 2/8/07, Andy Parkins [off-list ref] wrote:
On Thursday 2007 February 08 08:39, Marco Costalba wrote:
quoted
Regarding "Monospace" it should be changeable with Settings menu and
should apply _only_ to fixed space font viewers, in our case only
patch viewer and file content viewer.
The log message was the one I changed. Having the log message in variable
width breaks any ascii-art in the message.
I completely agree about pulling the setting from the config. I'll see if I
can find that and post a further patch.
quoted
If you see Monospace applied to list view or any other widget apart
from the above mentioned ones then it's a bug.
True. I used "Monospaced" as the font as that defaults to the system-wide
monospaced font; however it's pretty poor form. I raise my hand - shoot
me :-) As I say, I'll try and do better and send a new patch.
I have applied and pushed all your patches. BTW you are referring to
qgit4 at Pasky http://repo.or.cz/ site, not the stable qgit in
kernel.org repo!
I didn't got it unti I tried to apply the patches :-)
Hint: Regarding application 'fixed width' font please refer to
TYPE_WRITER_FONT variable defined in common.h in your new patch, this
is where user choosen font is stored.
Not-fixed-width font is set with qtconfig tool.
Marco
P.S: Yes, I have noted this Qt::convertFromPlainText() misbehaviour,
but I don't know if are the spaces that are not escaped correctly by
the function or the QTextEdit rendering engine that eats the (escaped)
spaces anyway.
P.P.S: Give a try to Bitstream Vera Sans Mono as fixed width font,
it's muuuuuch better then Monospace IMHO ;-)
From: Andy Parkins <hidden> Date: 2016-06-15 22:42:53
On Thursday 2007, February 08 19:06, Marco Costalba wrote:
I have applied and pushed all your patches. BTW you are referring to
qgit4 at Pasky http://repo.or.cz/ site, not the stable qgit in
kernel.org repo!
My apologies - that was the first one I found when I typed qgit4
repository.
Hint: Regarding application 'fixed width' font please refer to
TYPE_WRITER_FONT variable defined in common.h in your new patch,
this is where user choosen font is stored.
Excellent; I'll use that then. More patches coming soon. I hope the
git list is the right place for these patches.
P.S: Yes, I have noted this Qt::convertFromPlainText() misbehaviour,
but I don't know if are the spaces that are not escaped correctly by
the function or the QTextEdit rendering engine that eats the
(escaped) spaces anyway.
I definitely think this is a bug in Qt; QTextBrowser will show the
spaces in HTML mode if <pre> is used, so I don't think it's a fault in
QTextBrowser.
P.P.S: Give a try to Bitstream Vera Sans Mono as fixed width font,
it's muuuuuch better then Monospace IMHO ;-)
No need to persuade me; that's what I already use. Monospace isn't a
font on most systems - it's an alias to the default monospaced font -
and for me it's aliased to Bitstream Mono :-)
It seems to be done by the following in /etc/fonts/
<alias>
<family>Bitstream Vera Sans Mono</family>
<family>DejaVu Sans Mono</family>
<family>Courier</family>
<family>Courier New</family>
<family>Andale Mono</family>
<family>Luxi Mono</family>
<family>Cumberland AMT</family>
<family>Nimbus Mono L</family>
<family>NSimSun</family>
<family>FreeMono</family>
<default><family>monospace</family></default>
</alias>
In case that helps you.
Andy
--
Dr Andrew Parkins, M Eng (Hons), AMIEE
andyparkins@gmail.com
From: Marco Costalba <hidden> Date: 2016-06-15 22:42:53
On 2/8/07, Andy Parkins [off-list ref] wrote:
On Thursday 2007, February 08 19:06, Marco Costalba wrote:
quoted
I have applied and pushed all your patches. BTW you are referring to
qgit4 at Pasky http://repo.or.cz/ site, not the stable qgit in
kernel.org repo!
My apologies - that was the first one I found when I typed qgit4
repository.
No problem, stable qgit has less layout problems, probably the only
patch I will back port is the fixed font in log viewer.
qgit4 seems to have more layout weirdeness also in patch and file
tabs. I didn't fixed it until because I'm still wondering if it is
enough fixing the layout using stretch factors or bite the bullet and
implement a geometry persistent saving with QSettings (Qt4 is quite
powerful in this regard), of course saved geometry should work both
with maximized and not-maximized window, so perhaps saving
panes/splitters factors is better then save absolute value at least
for 'internal' widget, and use absolute window geometry only for qgit
main window.
quoted
P.S: Yes, I have noted this Qt::convertFromPlainText() misbehaviour,
but I don't know if are the spaces that are not escaped correctly by
the function or the QTextEdit rendering engine that eats the
(escaped) spaces anyway.
I definitely think this is a bug in Qt; QTextBrowser will show the
spaces in HTML mode if <pre> is used, so I don't think it's a fault in
QTextBrowser.
Please add dbg(text) line in git.cpp, just below
Qt::convertFromPlainText(text) call
text.append("\n\n " + colorMatch(c->shortLog(), shortLogRE) +
'\n' + colorMatch(c->longLog(), longLogRE));
}
text = Qt::convertFromPlainText(text);
dbg(text);
// highlight SHA's
//
// added to commit logs, we avoid to call git rev-parse for a
possible abbreviated
// sha if there isn't a leading trailing space or an open parenthesis and,
This will print the converted text as plain string, as you can see
there is 'something' instead of spaces but I cannot guess what.
quoted
P.P.S: Give a try to Bitstream Vera Sans Mono as fixed width font,
it's muuuuuch better then Monospace IMHO ;-)
No need to persuade me; that's what I already use. Monospace isn't a
font on most systems - it's an alias to the default monospaced font -
and for me it's aliased to Bitstream Mono :-)
It seems to be done by the following in /etc/fonts/
<alias>
<family>Bitstream Vera Sans Mono</family>
<family>DejaVu Sans Mono</family>
<family>Courier</family>
<family>Courier New</family>
<family>Andale Mono</family>
<family>Luxi Mono</family>
<family>Cumberland AMT</family>
<family>Nimbus Mono L</family>
<family>NSimSun</family>
<family>FreeMono</family>
<default><family>monospace</family></default>
</alias>
In case that helps you.
From: Marco Costalba <hidden> Date: 2016-06-15 22:42:53
On 2/8/07, Marco Costalba [off-list ref] wrote:
On 2/8/07, Andy Parkins [off-list ref] wrote:
quoted
On Thursday 2007, February 08 19:06, Marco Costalba wrote:
quoted
I have applied and pushed all your patches. BTW you are referring to
qgit4 at Pasky http://repo.or.cz/ site, not the stable qgit in
kernel.org repo!
My apologies - that was the first one I found when I typed qgit4
repository.
No problem, stable qgit has less layout problems, probably the only
patch I will back port is the fixed font in log viewer.
And also the short log resize mode one, sorry, I forget to mention.
BTW it's a little bit funny when you try to resize with mouse the
author column and see short log column moving instead :-)
Marco
From: Andy Parkins <hidden> Date: 2016-06-15 22:42:53
On Thursday 2007, February 08 19:51, Marco Costalba wrote:
BTW it's a little bit funny when you try to resize with mouse the
author column and see short log column moving instead :-)
Yeah, I'm not entirely sure I like it. What I really want, but Qt won't
do it is
* all columns resizable
* default date width to fit contents
* columns always take up whole width of view, never introducing a
horizontal scrollbar
If you want to drop it, I won't be upset. It is very disconcerting, the
only thing in that patches favour is that the view starts out basically
correct.
Andy
--
Dr Andrew Parkins, M Eng (Hons), AMIEE
andyparkins@gmail.com
From: Andy Parkins <hidden> Date: 2016-06-15 22:42:53
On Thursday 2007, February 08 19:29, Marco Costalba wrote:
qgit4 seems to have more layout weirdeness also in patch and file
tabs. I didn't fixed it until because I'm still wondering if it is
enough fixing the layout using stretch factors or bite the bullet and
implement a geometry persistent saving with QSettings (Qt4 is quite
powerful in this regard), of course saved geometry should work both
with maximized and not-maximized window, so perhaps saving
panes/splitters factors is better then save absolute value at least
for 'internal' widget, and use absolute window geometry only for qgit
main window.
Saving factors is definitely the way to go; and then you may as well use
the stretch factors as that's all they are in essence. Setting a 3:1
stretch ratio would be the same as setting 75% and 25% factors. The
ideal solution is really to set one of them based on the contents,
probably the file list; but that's difficult to do as you don't want
excessively deep trees to make the thing stupidly wide. In the end, I
think making layouts that work in all situations in near impossible, so
I usually just go for stretch factors that make it look reasonable in
most situations.
Please add dbg(text) line in git.cpp, just below
Qt::convertFromPlainText(text) call
text.append("\n\n " + colorMatch(c->shortLog(), shortLogRE) +
'\n' + colorMatch(c->longLog(), longLogRE));
}
text = Qt::convertFromPlainText(text);
dbg(text);
Good idea. I tried it and the problem would seem to be that
convertFromPlainText() doesn't do the conversion as completely as it
should. The spaces are being left as spaces, but of course when those
get passed to the HTML-ish parser of QTextBrowser, the spaces are being
swallowed - as with all HTML parsers. I believe it should actually be
replacing all the spaces with " " to /really/ do the plain->HTML
conversion. However, the point is moot now anyway because I've dropped
it in favour of a div with "white-space: pre" set, which does the job.
Andy
--
Dr Andrew Parkins, M Eng (Hons), AMIEE
andyparkins@gmail.com
From: Andy Parkins <hidden> Date: 2016-06-15 22:42:53
The font is now set in software and is made up of both variable and
monospaced fonts, therefore this override is no longer appropriate.
Signed-off-by: Andy Parkins <redacted>
---
src/revsview.ui | 5 -----
1 files changed, 0 insertions(+), 5 deletions(-)
From: Andy Parkins <hidden> Date: 2016-06-15 22:42:53
This stops the file list taking up half the screen by default. The
exact ratio is probably not to important, as long as it's not 1:1.
Signed-off-by: Andy Parkins <redacted>
---
src/patchview.ui | 16 ++++++++++++++++
1 files changed, 16 insertions(+), 0 deletions(-)
From: Andy Parkins <hidden> Date: 2016-06-15 22:42:53
I've moved the short log to be the first header row, and highlighted it
more strongly. I've also set the font family of the log div based on
TYPE_WRITER_FONT as suggested by Marco.
Signed-off-by: Andy Parkins <redacted>
---
src/git.cpp | 23 ++++++++++++++++-------
1 files changed, 16 insertions(+), 7 deletions(-)
From: Shawn O. Pearce <hidden> Date: 2016-06-15 22:42:53
In case you did not already know, --numbered is a wonderful option
to git-format-patch. It automatically numbers the commits by placing
a sequence into the subject header (e.g. [PATCH 1/3]), making it
easier for everyone to know how many patches are in your series.
--
Shawn.
From: Marco Costalba <hidden> Date: 2016-06-15 22:42:53
On 2/9/07, Andy Parkins [off-list ref] wrote:
I've moved the short log to be the first header row, and highlighted it
more strongly. I've also set the font family of the log div based on
TYPE_WRITER_FONT as suggested by Marco.
Signed-off-by: Andy Parkins <redacted>
---
This patch does not apply on my qgit4 repo, it seems it is on the top
of a your not published previous patch. Could you please rebase
against current public qgi4 repo (git://repo.or.cz/qgit4.git)
Other two patches has been applied and pushed.
Thanks
Marco