History log of /haiku/src/preferences/screen/ScreenMode.cpp
Revision Date Author Comments
# 28d2323a 03-Apr-2024 Daniel Martin <dalmemail@gmail.com>

screen: use B_COUNT_OF(), no functional changes

Change-Id: I827da35d9c04ed3d4884d477a1904f1ff4a4aad1
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7588
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>


# 76025887 18-Aug-2023 Augustin Cavalier <waddlesplash@gmail.com>

Screen: Make some manual edits to Vendors.h.

This data comes from the PNP registry, where deprecated entries
have "DO NOT USE". But those deprecated entries were often once used
in actual products, and we don't want to display "DO NOT USE" for them.
So remove such text, and replace it with the actual vendor name in a few places.


# 2eaee4a7 29-Aug-2022 JackBurton79 <stefano.ceccherini@gmail.com>

Screen preflet: fix usage of std::find()

Change-Id: I8689ea6baa408d07c715703e8f8bf8f29bf40f60
std::find() never returns NULL but the last element in case of failure
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5602
Reviewed-by: Máximo Castañeda <antiswen@yahoo.es>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>


# 7b3d134f 25-Aug-2022 JackBurton79 <stefano.ceccherini@gmail.com>

Screen preflet: fix possible NULL pointer dereference

Change-Id: Ia343cb2cba23f02d5504dfb849a059f041138119
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5571
Reviewed-by: waddlesplash <waddlesplash@gmail.com>


# fca54d80 24-Aug-2022 JackBurton79 <stefano.ceccherini@gmail.com>

Screen preflet: fix extra spaces in certain vendor code

Also fix a copy/paste error in the command used to generate the list and renamed the temp file

Change-Id: I0a954c78b14ddc802d3c5864323e7a1d82a529b9
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5567
Reviewed-by: Oscar Lesta <oscar.lesta@gmail.com>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>


# 9990382d 09-Aug-2022 JackBurton79 <stefano.ceccherini@gmail.com>

Screen preflet: add and use a 'database' for screen vendors.

Change-Id: Ibf6435b29b3ac509c1e4c5a2331840600838301b
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5535
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>


# c35e9b90 19-May-2022 Jérôme Duval <jerome.duval@gmail.com>

ScreenMode: add some manufacturers

Change-Id: Id3eea56f5e0d453817eaedb4f1d6a6014af8f9e3
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5321
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 0bc2edbd 31-Jul-2019 Adrien Destugues <pulkomandy@pulkomandy.tk>

ScreenMode: add some manufacturers

Taken from http://edid.tv/manufacturer/

Mostly so my laptop properly identifies as Seiko Epson.

Change-Id: Ie04cb6593e87f3509a7158948d5ae85b10148fcb
Reviewed-on: https://review.haiku-os.org/c/1668
Reviewed-by: waddlesplash <waddlesplash@gmail.com>


# c33a865c 31-Jan-2013 John Scipione <jscipione@gmail.com>

Style fixes only.


# df9db786 11-Sep-2011 Axel Dörfler <axeld@pinc-software.de>

* Added methods to work with display_modes directly.
* Cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42735 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0c4f821c 19-Jul-2011 Axel Dörfler <axeld@pinc-software.de>

* Removed the previous version of the GTF function, since a few rounding errors
have been introduced, and also support for interlace mode had been removed.
* Instead, the Screen preferences are now using the common accelerant code for
this.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42451 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 2d73faba 13-Apr-2010 Jérôme Duval <korli@users.berlios.de>

clean up (white spaces, spacing and parenthesis)
added a TODO about using kMaxWorkspaces in ScreenMode.cpp


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36242 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 61c5c89b 14-Dec-2009 Axel Dörfler <axeld@pinc-software.de>

* Added info about the graphics device as suggested in #5112. However, it's
currently only shown in the monitor tool tip, that is now feels a bit crowded,
so a better solution would be nice. I'm hesitant to give it a more prominent
position, though, unless one has proof-read what the accelerants actually
return here.
* Added missing space between the serial number of the monitor and the date it
has been produced.
* Renamed fTempScreenMode to fUndoScreenMode, as it's only used to deliver that
functionality.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34659 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1e6b39c3 10-Dec-2009 Axel Dörfler <axeld@pinc-software.de>

* Patch by Gerald to set a fallback range in case no EDID info was provided.
* This fixes bug #4572.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34627 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1fc4cb1f 07-Aug-2009 Axel Dörfler <axeld@pinc-software.de>

* If the user selected color space is not available for the selected resolution,
_CheckColorMenu() now selects the closest item available - if you switch back
the resolution to one that supports the original color space, it will be
restored. This fixes bug #2995.
* I also reverted r24674 as I remembered why I did that in the first place
(advertizing 24 bit modes as 32 bit), and it was a pretty stupid idea to
solve it like this, I must admit.
* Instead, the color space menu now only shows spaces that are actually
supported by the card at all. One could think about hiding 24 bit in case
both 24 bit, and 32 bit are available, but I didn't do that yet.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32179 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1e4b23da 04-Aug-2009 Axel Dörfler <axeld@pinc-software.de>

* Added more vendor entries, thanks to Brecht again for digging up another
resource.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32111 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 90d0584d 31-Jul-2009 Rene Gollent <anevilyak@gmail.com>

Added vendor ID for Gateway. Thanks Urias!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32055 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 447c2a84 31-Jul-2009 Rene Gollent <anevilyak@gmail.com>

Add some more vendor IDs gleaned from some of my monitors here, Urias and one of linux's EDID quirks files.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32054 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c9d653c1 31-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

* Added many many more vendors, thanks to Brecht for digging up a nice web
resource that I couldn't find! Also thanks to Jonas and Urias :-)
* Header cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32049 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3b90428b 31-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

* Added two more vendors found by Urias, thanks! If anyone has a SONY (SNY?),
Dell, or Acer monitor, those are still missing as well.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32041 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ca9e658b 31-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

* Added Eizo, thanks Jonas.
* Added comment to monitor_info::name retrieval via EDID1_MONITOR_NAME.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32040 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a717876d 31-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

* Added some more vendor names, taken from the syslog data in our bug
tracker :-)
* Improved monitor name, based on that data as well.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32036 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 16dac19e 31-Jul-2009 Rene Gollent <anevilyak@gmail.com>

gcc4 build fix.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32031 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 12966d04 31-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

* Now shows some info about the monitor if detected.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32030 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8f30149c 31-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

* Work-in-progress commit.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32023 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 2c5fedae 20-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

Applied patch by Gerald Zajac, revised by me to match our coding style:
* imported X.org's GTF function, and use it to compute modes that are not on
the list.
* Also, accept a 6% variation for the selected mode refresh rate.
* Automatic whitespace cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31654 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d0eaec30 01-Feb-2009 Michael Lotz <mmlr@mlotz.ch>

Fix more operator precedence errors. These do not do what you'd expect at first
sight. The comparison operator takes precedence over the binary ones.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29121 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5de171da 30-Mar-2008 Axel Dörfler <axeld@pinc-software.de>

* Now presents 24 bit modes as 32 bit modes to the user to avoid confusion.
* screen_mode will not make a difference between 32 and 24 bit anymore in the
equally operator.
* Some cards only support 24 bit instead of 32, for example Qemu VESA mode.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24674 a95241bf-73f2-0310-859d-f6bbb57e9c96


# abc649b8 07-Feb-2007 Waldemar Kornewald <wkornewald@nowhere.fake>

Made the Screen preflet's behavior consistent with the other preflets.
* Moved Apply button into controls box (resolution, etc.), so its meaning is more obvious.
* Revert now resets the whole screen settings for all workspaces to the configuration at the start of the preflet.
* In confirmation window, renamed Revert to Undo because that's what it actually does (it has nothing to do with the Revert in the main dialog).
* Disabled Defaults button (for now) since it doesn't use the screen's preferred settings and added a few TODOs.
* This should fix bug #321.
Note: Unfortunately, it won't work correctly on R5 because BScreen can only access the active workspace, it seems (locally, I used activate_workspace() for testing the preflet). Also, Haiku doesn't yet support setting screen preferences for each workspace individually, so I couldn't test it.
I hope my code isn't too terrible. :)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20096 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a40498e2 01-Feb-2007 Waldemar Kornewald <wkornewald@nowhere.fake>

* Fixed a little bug that caused unnecessary mode changes when pressing Revert.
* Fixed compilation under R5.
* Made Revert more user-friendly by also allowing to revert settings to the previously active state after having pressed Apply. This only works if you didn't make new changes in the meantime. In that case, only the new changes will be reverted.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20031 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 29e8a73a 25-Mar-2006 Axel Dörfler <axeld@pinc-software.de>

* No longer ignores the screen refresh limits from the driver.
* Now builds under R5, but looks ugly (for testing only).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16877 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a10cf76e 24-Jun-2005 Axel Dörfler <axeld@pinc-software.de>

Renamed src/prefs to "preferences", as the directory is usually called in BeOS.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13263 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c33a865c7c3ce73ab74354a41ac83cf4de20d726 31-Jan-2013 John Scipione <jscipione@gmail.com>

Style fixes only.


# df9db7862b4368cf7fed1094836f80013119254d 11-Sep-2011 Axel Dörfler <axeld@pinc-software.de>

* Added methods to work with display_modes directly.
* Cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42735 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0c4f821caac245dd1aff2688be85eab8c9cdecb0 19-Jul-2011 Axel Dörfler <axeld@pinc-software.de>

* Removed the previous version of the GTF function, since a few rounding errors
have been introduced, and also support for interlace mode had been removed.
* Instead, the Screen preferences are now using the common accelerant code for
this.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42451 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 2d73faba95c911a11d8a4a2070c47d47250ed9a9 13-Apr-2010 Jérôme Duval <korli@users.berlios.de>

clean up (white spaces, spacing and parenthesis)
added a TODO about using kMaxWorkspaces in ScreenMode.cpp


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36242 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 61c5c89b6d6c0c132cdcfb42dc0369ca02c17649 14-Dec-2009 Axel Dörfler <axeld@pinc-software.de>

* Added info about the graphics device as suggested in #5112. However, it's
currently only shown in the monitor tool tip, that is now feels a bit crowded,
so a better solution would be nice. I'm hesitant to give it a more prominent
position, though, unless one has proof-read what the accelerants actually
return here.
* Added missing space between the serial number of the monitor and the date it
has been produced.
* Renamed fTempScreenMode to fUndoScreenMode, as it's only used to deliver that
functionality.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34659 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1e6b39c341e64d16581478b65b7d7d17ca4cda9b 10-Dec-2009 Axel Dörfler <axeld@pinc-software.de>

* Patch by Gerald to set a fallback range in case no EDID info was provided.
* This fixes bug #4572.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34627 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1fc4cb1f275d1c970745decfec43e1e532716834 07-Aug-2009 Axel Dörfler <axeld@pinc-software.de>

* If the user selected color space is not available for the selected resolution,
_CheckColorMenu() now selects the closest item available - if you switch back
the resolution to one that supports the original color space, it will be
restored. This fixes bug #2995.
* I also reverted r24674 as I remembered why I did that in the first place
(advertizing 24 bit modes as 32 bit), and it was a pretty stupid idea to
solve it like this, I must admit.
* Instead, the color space menu now only shows spaces that are actually
supported by the card at all. One could think about hiding 24 bit in case
both 24 bit, and 32 bit are available, but I didn't do that yet.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32179 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1e4b23dae21985408452f0cf17d5dcb65343c221 04-Aug-2009 Axel Dörfler <axeld@pinc-software.de>

* Added more vendor entries, thanks to Brecht again for digging up another
resource.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32111 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 90d0584d89784d4e7bb31935343b85f1fc121f52 31-Jul-2009 Rene Gollent <anevilyak@gmail.com>

Added vendor ID for Gateway. Thanks Urias!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32055 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 447c2a84b9e4220428dc5c505d1c4312f20fe143 31-Jul-2009 Rene Gollent <anevilyak@gmail.com>

Add some more vendor IDs gleaned from some of my monitors here, Urias and one of linux's EDID quirks files.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32054 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c9d653c1de5a3975d98f704282b9c8abb20b7b04 31-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

* Added many many more vendors, thanks to Brecht for digging up a nice web
resource that I couldn't find! Also thanks to Jonas and Urias :-)
* Header cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32049 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3b90428b4a4f61ca51da08869decb6271ce2b104 31-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

* Added two more vendors found by Urias, thanks! If anyone has a SONY (SNY?),
Dell, or Acer monitor, those are still missing as well.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32041 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ca9e658bd9dec384a8c8e863da7e25ff7ada08e8 31-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

* Added Eizo, thanks Jonas.
* Added comment to monitor_info::name retrieval via EDID1_MONITOR_NAME.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32040 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a717876d047db5832a46f44ada468a2bb27fc0f8 31-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

* Added some more vendor names, taken from the syslog data in our bug
tracker :-)
* Improved monitor name, based on that data as well.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32036 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 16dac19ef795ecf13d9c224b2c7e3f478c4fbefe 31-Jul-2009 Rene Gollent <anevilyak@gmail.com>

gcc4 build fix.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32031 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 12966d04e9769e8f1e86b9c81c367a80ea7a6b23 31-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

* Now shows some info about the monitor if detected.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32030 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8f30149c061f177bb6d2a28ca650a5d0acda9509 31-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

* Work-in-progress commit.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32023 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 2c5fedae4b71698918b97111903023772f354b02 20-Jul-2009 Axel Dörfler <axeld@pinc-software.de>

Applied patch by Gerald Zajac, revised by me to match our coding style:
* imported X.org's GTF function, and use it to compute modes that are not on
the list.
* Also, accept a 6% variation for the selected mode refresh rate.
* Automatic whitespace cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31654 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d0eaec308617fe6623df22fb2e41308517c5d7cb 01-Feb-2009 Michael Lotz <mmlr@mlotz.ch>

Fix more operator precedence errors. These do not do what you'd expect at first
sight. The comparison operator takes precedence over the binary ones.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29121 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5de171daf3ba89574a56fbf7cd9eec41646ce091 30-Mar-2008 Axel Dörfler <axeld@pinc-software.de>

* Now presents 24 bit modes as 32 bit modes to the user to avoid confusion.
* screen_mode will not make a difference between 32 and 24 bit anymore in the
equally operator.
* Some cards only support 24 bit instead of 32, for example Qemu VESA mode.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24674 a95241bf-73f2-0310-859d-f6bbb57e9c96


# abc649b8689b9f87bf15b353bd2473b5d308911a 07-Feb-2007 Waldemar Kornewald <wkornewald@nowhere.fake>

Made the Screen preflet's behavior consistent with the other preflets.
* Moved Apply button into controls box (resolution, etc.), so its meaning is more obvious.
* Revert now resets the whole screen settings for all workspaces to the configuration at the start of the preflet.
* In confirmation window, renamed Revert to Undo because that's what it actually does (it has nothing to do with the Revert in the main dialog).
* Disabled Defaults button (for now) since it doesn't use the screen's preferred settings and added a few TODOs.
* This should fix bug #321.
Note: Unfortunately, it won't work correctly on R5 because BScreen can only access the active workspace, it seems (locally, I used activate_workspace() for testing the preflet). Also, Haiku doesn't yet support setting screen preferences for each workspace individually, so I couldn't test it.
I hope my code isn't too terrible. :)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20096 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a40498e2b2d2bdbe296823c96407f6ed67759a9e 01-Feb-2007 Waldemar Kornewald <wkornewald@nowhere.fake>

* Fixed a little bug that caused unnecessary mode changes when pressing Revert.
* Fixed compilation under R5.
* Made Revert more user-friendly by also allowing to revert settings to the previously active state after having pressed Apply. This only works if you didn't make new changes in the meantime. In that case, only the new changes will be reverted.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20031 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 29e8a73a07ad05379041635507d5a55c65c8d71c 25-Mar-2006 Axel Dörfler <axeld@pinc-software.de>

* No longer ignores the screen refresh limits from the driver.
* Now builds under R5, but looks ugly (for testing only).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16877 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a10cf76ef5b9e8c726ebc47183abd6943023cf8f 24-Jun-2005 Axel Dörfler <axeld@pinc-software.de>

Renamed src/prefs to "preferences", as the directory is usually called in BeOS.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13263 a95241bf-73f2-0310-859d-f6bbb57e9c96