From 18c20b03508abb92de97d05d40da864841418754 Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Tue, 1 Mar 2005 20:50:06 +0000 Subject: give up trying to only add modelines not defined in xorg, otherwise xorg will prefer the modelines we give here (eg: it will use 1024x768@50 whereas it could use 1024x768@60) --- perl-install/Xconfig/xfree.pm | 38 ++++++++++---------------------------- 1 file changed, 10 insertions(+), 28 deletions(-) (limited to 'perl-install/Xconfig') diff --git a/perl-install/Xconfig/xfree.pm b/perl-install/Xconfig/xfree.pm index a21f3cff5..f6d6c715b 100644 --- a/perl-install/Xconfig/xfree.pm +++ b/perl-install/Xconfig/xfree.pm @@ -303,14 +303,16 @@ sub add_gtf_ModeLines { my $banner = 'modeline generated by gtf(1) [handled by XFdrake]'; my $res = $resolution->{X} . 'x' . $resolution->{Y}; - my @freqs = difference2(\@Xconfig::xfree::vfreqs, [ split(' ', $Xconfig::xfree::builtin_ModeLines{$res}) ]); - my @to_add = map { - my $s = run_program::rooted_get_stdout($::prefix, 'gtf', $resolution->{X}, $resolution->{Y}, $_); - my ($name, $val) = $s =~ /ModeLine\s*"(.*)"(.*)/i; - chomp $val; - $name =~ s/\.00//; #- nicer that way - { val => qq("${name}"$val), pre_comment => "# $banner\n" }; - } @freqs; + my @to_add; + if ($resolution2ratio{$res} ne '4/3') { + @to_add = map { + my $s = run_program::rooted_get_stdout($::prefix, 'gtf', $resolution->{X}, $resolution->{Y}, $_); + my ($name, $val) = $s =~ /ModeLine\s*"(.*)"(.*)/i; + chomp $val; + $name =~ s/\.00//; #- nicer that way + { val => qq("${name}"$val), pre_comment => "# $banner\n" }; + } @Xconfig::xfree::vfreqs; + } $raw_X->set_monitors(map { @{$_->{ModeLine}} = ( @@ -592,26 +594,6 @@ foreach my $ratio (keys %ratio2resolutions) { } } -our %builtin_ModeLines = ( -#- '640x350' => '85', # vesa -#- '640x400' => '85', # vesa -#- '720x400' => '85', # vesa - '640x480' => '60 72 75 85', # vesa - '800x600' => '56 60 72 75 85', # vesa - '832x624' => '75', - '1024x768' => '43 60 70 75 85', # vesa - '1152x864' => '75', # vesa - '1280x960' => '60 85', # vesa - '1280x1024' => '60 75 85', # vesa - '1400x1050' => '60 75', - '1600x1024' => '60', - '1600x1200' => '60 65 70 75 85', # vesa - '1792x1344' => '60 75', # vesa - '1856x1392' => '60 75', # vesa - '1920x1440' => '60 75' . ' 85', # vesa + extra - '2048x1536' => '60 75 85', -); - our $default_header = <<'END'; # File generated by XFdrake. -- cgit v1.2.1