<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>E-Ink on kenji.blog</title><link>http://kenji.blog/en/tags/e-ink/</link><description>Recent content in E-Ink on kenji.blog</description><generator>Hugo -- gohugo.io</generator><language>en</language><copyright>kenjinote</copyright><lastBuildDate>Sat, 12 Sep 2026 12:00:00 +0900</lastBuildDate><atom:link href="http://kenji.blog/en/tags/e-ink/index.xml" rel="self" type="application/rss+xml"/><item><title>Gadgets and Monitor Settings to Reduce Programmer's Eye Strain</title><link>http://kenji.blog/en/p/programmer-eye-strain-relief/</link><pubDate>Sat, 12 Sep 2026 12:00:00 +0900</pubDate><guid>http://kenji.blog/en/p/programmer-eye-strain-relief/</guid><description>&lt;img src="http://kenji.blog/p/programmer-eye-strain-relief/img/eyecatch.jpg" alt="Featured image of post Gadgets and Monitor Settings to Reduce Programmer's Eye Strain" />&lt;p>For programmers and software engineers, the &amp;ldquo;eyes&amp;rdquo; are their most important and heavily abused tools of the trade. Spending 8 to 10 hours a day, sometimes even more, constantly looking at editors, terminals, and browser screens, almost every engineer faces &amp;ldquo;Computer Vision Syndrome&amp;rdquo; (CVS) or eye strain.&lt;/p>
&lt;p>Generally, countermeasures against eye strain tend to end with superficial advice such as &amp;ldquo;use eye drops,&amp;rdquo; &amp;ldquo;take appropriate breaks,&amp;rdquo; or &amp;ldquo;wear blue light blocking glasses.&amp;rdquo; However, as engineers, we should identify the root cause of the problem and optimize it from the system (environment) layer.&lt;/p>
&lt;p>In this article, we will thoroughly dissect the mechanics of a programmer&amp;rsquo;s eye strain from the perspectives of physics (optics), biochemistry, ergonomics, and display hardware architecture. We will delve deeply into the ultimate monitor settings and gadgets to relieve it, using mathematical formulas and illustrations.&lt;/p>
&lt;hr>
&lt;h1 id="chapter-1-unraveling-the-mechanics-of-eye-strain-cvs-through-physics-and-biochemistry">Chapter 1: Unraveling the Mechanics of Eye Strain (CVS) Through Physics and Biochemistry
&lt;/h1>&lt;p>Computer Vision Syndrome (CVS) is not caused by a single factor. As shown in the pie chart below, various elements are complexly intertwined, leading to eye fatigue, pain, dry eyes, and overall bodily fatigue.&lt;/p>
&lt;pre class="mermaid">
pie title Causes of Computer Vision Syndrome (CVS)
&amp;#34;Blue Light &amp;amp; Glare&amp;#34; : 30
&amp;#34;Screen Flickering (PWM)&amp;#34; : 25
&amp;#34;Improper Contrast &amp;amp; Lighting&amp;#34; : 20
&amp;#34;Focus Fatigue (Ciliary Muscle)&amp;#34; : 15
&amp;#34;Dry Eyes (Reduced Blinking)&amp;#34; : 10
&lt;/pre>
&lt;p>Here, we will explain the &amp;ldquo;physical properties of light&amp;rdquo; and the &amp;ldquo;focus adjustment function of the eyeball,&amp;rdquo; which have particularly significant impacts.&lt;/p>
&lt;h2 id="11-physical-properties-of-blue-light-and-photon-energy">1.1 Physical Properties of Blue Light and Photon Energy
&lt;/h2>&lt;p>Blue light emitted from displays is located roughly in the wavelength band of $400 \text{ nm} \sim 490 \text{ nm}$. The reason why this puts a strain on the eyes can be explained by the &amp;ldquo;Planck-Einstein relation,&amp;rdquo; which is the foundation of quantum mechanics.&lt;/p>
&lt;p>The energy of light $E$ is expressed by the following formula:&lt;/p>
$$ E = h\nu = \frac{hc}{\lambda} $$&lt;p>Here, each variable has the following meaning:&lt;/p>
&lt;ul>
&lt;li>$E$ : Energy per photon (Joule)&lt;/li>
&lt;li>$h$ : Planck constant ($6.626 \times 10^{-34} \text{ J}\cdot\text{s}$)&lt;/li>
&lt;li>$c$ : Speed of light in a vacuum ($3.0 \times 10^8 \text{ m/s}$)&lt;/li>
&lt;li>$\lambda$ : Wavelength of light (m)&lt;/li>
&lt;li>$\nu$ : Frequency of light (Hz)&lt;/li>
&lt;/ul>
&lt;p>The important fact indicated by this formula is that &lt;strong>&amp;ldquo;the energy of light $E$ is inversely proportional to the wavelength $\lambda$.&amp;rdquo;&lt;/strong> In other words, blue light, which has the shortest wavelength among visible light, possesses extremely high energy. These high-energy photons are less likely to be absorbed or attenuated by the cornea or crystalline lens, reaching deep into the retina and applying strong oxidative stress to the photoreceptor cells.&lt;/p>
&lt;h2 id="12-chromatic-aberration-and-focus-shift">1.2 Chromatic Aberration and Focus Shift
&lt;/h2>&lt;p>Furthermore, from an optical perspective, differences in the wavelength of light create differences in the &amp;ldquo;refractive index.&amp;rdquo; The refractive index $n$ of a medium (such as the crystalline lens in this case) depends on the wavelength $\lambda$, and is approximated by Cauchy&amp;rsquo;s equation:&lt;/p>
$$ n(\lambda) = B + \frac{C}{\lambda^2} $$&lt;p>($B, C$ are constants unique to the medium)&lt;/p>
&lt;p>As can be seen from this formula, the shorter the wavelength $\lambda$ of the blue light, the larger the refractive index $n$. Therefore, even if red light is perfectly focused on the retina, blue light is strongly refracted and comes to a focus &lt;strong>in front of the retina&lt;/strong>.
When the brain recognizes this &amp;ldquo;image blurring due to blue light (chromatic aberration),&amp;rdquo; it constantly sends commands to the ciliary muscle to unconsciously try to refocus. This is a major factor in the unconscious fatigue of the eye muscles.&lt;/p>
&lt;h2 id="13-focus-adjustment-muscle-ciliary-muscle-and-thin-lens-equation">1.3 Focus Adjustment Muscle (Ciliary Muscle) and Thin Lens Equation
&lt;/h2>&lt;p>When we focus on fine text on a monitor, we adjust the thickness of the crystalline lens inside our eyes. The thin lens equation is as follows:&lt;/p>
$$ \frac{1}{f} = \frac{1}{a} + \frac{1}{b} $$&lt;ul>
&lt;li>$f$: Focal length of the crystalline lens&lt;/li>
&lt;li>$a$: Distance from the eye to the monitor (object distance)&lt;/li>
&lt;li>$b$: Distance from the crystalline lens to the retina (image distance: constant at about $24 \text{ mm}$ in an adult eyeball)&lt;/li>
&lt;/ul>
&lt;p>During programming, if the distance $a$ to the monitor is kept short (e.g., $40 \text{ cm} \sim 50 \text{ cm}$) for a long time, the focal length $f$ must be kept extremely short in order to form an accurate image on the retina (keeping $b$ constant). If the ciliary muscle remains extremely contracted for hours, the muscle falls into a state of spasm, causing severe eye strain accompanied by stiff shoulders and headaches.&lt;/p>
&lt;hr>
&lt;h1 id="chapter-2-hardware-display-selection-and-elimination-of-fatigue-factors">Chapter 2: Hardware Display Selection and Elimination of Fatigue Factors
&lt;/h1>&lt;p>To alleviate eye fatigue, it is necessary to first verify and improve the hardware specifications before tweaking software settings. In particular, the &amp;ldquo;dimming method&amp;rdquo; and &amp;ldquo;refresh rate&amp;rdquo; are points where you should not compromise.&lt;/p>
&lt;h2 id="21-the-terror-of-pwm-dimming-uncovering-invisible-flicker">2.1 The Terror of PWM Dimming: Uncovering Invisible Flicker
&lt;/h2>&lt;p>The technologies for adjusting the brightness of LCD (Liquid Crystal Display) and OLED (Organic Light-Emitting Diode) monitors are broadly divided into &amp;ldquo;DC (Direct Current) dimming&amp;rdquo; and &amp;ldquo;PWM (Pulse-Width Modulation) dimming.&amp;rdquo;&lt;/p>
&lt;p>PWM dimming is a technology that blinks the backlight LEDs at a high speed invisible to the human eye, artificially adjusting screen brightness through the ratio of its &amp;ldquo;on time&amp;rdquo; to &amp;ldquo;off time.&amp;rdquo; The average brightness $L$ determined by the duty cycle of the PWM is expressed by the following equation:&lt;/p>
$$ L = L_{max} \times \frac{T_{on}}{T_{on} + T_{off}} \times 100 \ (\%) $$&lt;ul>
&lt;li>$T_{on}$ : Time the LED is on&lt;/li>
&lt;li>$T_{off}$ : Time the LED is off&lt;/li>
&lt;li>$L_{max}$ : Maximum peak brightness&lt;/li>
&lt;/ul>
&lt;p>When the frequency of PWM dimming is low (e.g., $200 \text{ Hz} \sim 300 \text{ Hz}$), even if you do not consciously perceive the screen flickering, the brain and pupils unconsciously react to the blinking light, repeatedly dilating and constricting. This induces extreme fatigue, headaches, and even nausea.&lt;/p>
&lt;p>&lt;strong>[How to Detect PWM and Countermeasures]&lt;/strong>
To check if your monitor uses PWM dimming, launch the camera app on your smartphone, set it to &amp;ldquo;slow-motion video&amp;rdquo; mode, and record a white screen on your monitor (like a blank browser page). If dark horizontal bands (banding) appear moving across the video, that monitor employs low-frequency PWM dimming.
When programmers choose a monitor, they should absolutely select one where the specifications clearly state &lt;strong>&amp;ldquo;Flicker-Free (DC dimming).&amp;rdquo;&lt;/strong>&lt;/p>
&lt;h2 id="22-ophthalmological-impact-of-refresh-rate-hz-and-motion-blur">2.2 Ophthalmological Impact of Refresh Rate (Hz) and Motion Blur
&lt;/h2>&lt;p>The refresh rate is a numerical value (Hz) indicating how many times the monitor redraws the screen per second.
Standard office monitors are $60 \text{ Hz}$, but high refresh rate monitors like $120 \text{ Hz}$ or $144 \text{ Hz}$ have become popular in recent years. This is extremely beneficial not only for gamers but also for programmers.&lt;/p>
&lt;p>When scrolling through massive amounts of code or when a large volume of logs flows in the terminal, a $60 \text{ Hz}$ display will experience &amp;ldquo;motion blur&amp;rdquo; (afterimages) combined with the limitations of pixel response times. The eye unconsciously tries to capture the shape of the text and keep it in focus even during scrolling, but if the characters are blurred, the processing load on the brain&amp;rsquo;s visual cortex spikes dramatically.
With a display of $120 \text{ Hz}$ or higher, text remains clearly visible even while scrolling, significantly reducing the burden of these unconscious eye movements and focus adjustments.&lt;/p>
&lt;h2 id="23-panel-types-and-contrast-ratio-ips-va-oled">2.3 Panel Types and Contrast Ratio (IPS, VA, OLED)
&lt;/h2>&lt;p>The contrast ratio of a screen directly affects text legibility.
The &amp;ldquo;Weber-Fechner Law,&amp;rdquo; which states that the magnitude of human sensation is proportional to the logarithm of the stimulus, is expressed by the following formula:&lt;/p>
$$ p = k \ln \left( \frac{S}{S_0} \right) $$&lt;p>($p$: magnitude of sensation, $S$: physical magnitude of stimulus, $S_0$: threshold, $k$: constant)&lt;/p>
&lt;p>In other words, the human eye reacts more strongly to the &amp;ldquo;relative brightness ratio (contrast)&amp;rdquo; than to absolute brightness.
When reading syntax-highlighted code for long periods, VA panels ($3000:1$) with deep blacks (high contrast ratio) or OLED panels ($1,000,000:1$ and up) that can completely turn off individual pixels make character outlines very clear and improve legibility.
However, as explained later, looking at an extremely high-contrast screen in a pitch-black room causes the pupils to constrict too much, leading to fatigue instead, so a balance with ambient light is essential.&lt;/p>
&lt;p>The chart below compares the conceptual emission spectrum of a standard LCD monitor with modern OLED (low blue light design).&lt;/p>
&lt;pre class="mermaid">
xychart-beta
title Blue Light Emission Spectrum Comparison
x-axis &amp;#34;Wavelength (nm)&amp;#34; [400, 420, 440, 460, 480, 500]
y-axis &amp;#34;Relative Intensity&amp;#34; 0 --&amp;gt; 100
bar &amp;#34;Standard LCD (W-LED)&amp;#34; [10, 30, 95, 80, 40, 20]
line &amp;#34;Modern OLED / Low Blue Light&amp;#34; [5, 10, 40, 75, 55, 30]
&lt;/pre>
&lt;hr>
&lt;h1 id="chapter-3-monitor-calibration-and-os--software-settings">Chapter 3: Monitor Calibration and OS / Software Settings
&lt;/h1>&lt;p>Equally as important as hardware selection is color space management and calibration on the OS side.&lt;/p>
&lt;h2 id="31-the-trap-of-color-gamut-srgb-vs-dci-p3-and-icc-profiles">3.1 The Trap of Color Gamut (sRGB vs DCI-P3) and ICC Profiles
&lt;/h2>&lt;p>Modern monitors often boast a &amp;ldquo;wide color gamut&amp;rdquo; such as 95%+ DCI-P3 coverage, but this can backfire for programming purposes.
In a Windows environment, if a wide color gamut monitor is used without applying the appropriate ICC profile (a color profile defined by the International Color Consortium), the syntax highlighting in VS Code, which is designated in standard sRGB (e.g., red or green warning colors), will be displayed in unnaturally vivid, oversaturated hues.
Because these intense colors strongly stimulate the eyes, it is highly recommended to either install the correct ICC profile from the OS display settings or switch the monitor&amp;rsquo;s OSD settings to &amp;ldquo;sRGB Emulation Mode.&amp;rdquo;&lt;/p>
&lt;p>The sequence diagram below illustrates the process of rendering eye-friendly colors once the correct ICC profile is applied.&lt;/p>
&lt;pre class="mermaid">
sequenceDiagram
participant OS as &amp;#34;Operating System&amp;#34;
participant LUT as &amp;#34;Color LUT (Look-Up Table)&amp;#34;
participant Mon as &amp;#34;Monitor Display&amp;#34;
participant Eye as &amp;#34;Programmer&amp;#39;s Eye&amp;#34;
OS-&amp;gt;&amp;gt;LUT: &amp;#34;Load Correct ICC Profile (e.g. sRGB)&amp;#34;
OS-&amp;gt;&amp;gt;LUT: &amp;#34;Apply Night Light Settings (3400K)&amp;#34;
LUT-&amp;gt;&amp;gt;Mon: &amp;#34;Adjust RGB Signal Output&amp;#34;
Mon-&amp;gt;&amp;gt;Eye: &amp;#34;Render Accurate, Desaturated Colors&amp;#34;
Eye--&amp;gt;&amp;gt;Eye: &amp;#34;Reduced Visual Cortical Strain&amp;#34;
&lt;/pre>
&lt;h2 id="32-software-countermeasures-flux--night-light">3.2 Software Countermeasures (f.lux / Night Light)
&lt;/h2>&lt;p>The easiest and most effective measure against blue light is software that dynamically changes the Color Temperature according to the time of day.&lt;/p>
&lt;ul>
&lt;li>Windows: &lt;strong>Night Light&lt;/strong>&lt;/li>
&lt;li>macOS: &lt;strong>Night Shift&lt;/strong>&lt;/li>
&lt;li>Third-party: &lt;strong>f.lux&lt;/strong>&lt;/li>
&lt;/ul>
&lt;p>Color temperature is expressed in Kelvin ($\text{K}$). Daytime sunlight is approximately $5500\text{K} \sim 6500\text{K}$ (bluish-white light), but if your eyes are constantly exposed to this, the secretion of &amp;ldquo;melatonin (sleep hormone)&amp;rdquo; in the pineal gland of the brain is suppressed.
After evening, by using these software tools to lower the color temperature down to $3400\text{K} \sim 1900\text{K}$ (warm orange to red), you can physically reduce the amount of blue light emitted. This not only keeps your circadian rhythm (body clock) normal but also prevents high-energy photons from reaching your eyeballs.&lt;/p>
&lt;hr>
&lt;h1 id="chapter-4-the-ultimate-hardware-solution-adopting-the-latest-gadgets">Chapter 4: The Ultimate Hardware Solution: Adopting the Latest Gadgets
&lt;/h1>&lt;p>If the measures explained so far fail to alleviate your fatigue, you need to invest in external gadgets to drastically change your environment.&lt;/p>
&lt;h2 id="41-bias-lighting-and-monitor-light-bars-screenbar">4.1 Bias Lighting and Monitor Light Bars (ScreenBar)
&lt;/h2>&lt;p>When you stare at a bright monitor in a dark room, a severe contrast occurs between the center of your field of vision (high brightness) and the periphery (low brightness). This is called &lt;strong>&amp;ldquo;Discomfort Glare.&amp;rdquo;&lt;/strong>
Under these conditions, the eyes fall into a contradictory state where they try to dilate the pupils to take in light while simultaneously trying to constrict them against the central glare, leading to severe fatigue of the iris muscles.&lt;/p>
&lt;p>The solution to this is &amp;ldquo;Bias Lighting.&amp;rdquo;
Particularly recommended are &amp;ldquo;monitor light bars&amp;rdquo; like the &lt;strong>BenQ ScreenBar&lt;/strong>.&lt;/p>
&lt;pre class="mermaid">
graph TD
A[&amp;#34;Dark Room Environment&amp;#34;] --&amp;gt; B[&amp;#34;High Brightness Contrast (Monitor vs Room)&amp;#34;]
B --&amp;gt; C[&amp;#34;Conflicting Pupil Constriction/Dilation&amp;#34;]
C --&amp;gt; D[&amp;#34;Severe Iris Muscle Fatigue&amp;#34;]
A --&amp;gt; E[&amp;#34;Install Monitor Light Bar (e.g., ScreenBar)&amp;#34;]
E --&amp;gt; F[&amp;#34;Asymmetrical Optical Design (No Glare on Screen)&amp;#34;]
F --&amp;gt; G[&amp;#34;Balanced Ambient Brightness&amp;#34;]
G --&amp;gt; H[&amp;#34;Relaxed Iris and Relieved Eye Strain&amp;#34;]
&lt;/pre>
&lt;p>The greatest feature of the ScreenBar is its &amp;ldquo;Asymmetrical Optical Design.&amp;rdquo; Through special reflectors and lenses, it does not shine light directly onto the monitor screen itself (preventing screen reflection and glare), and uniformly illuminates only the keyboard in front of you and the space behind the monitor. This dramatically mitigates the brightness difference (contrast ratio) across the entire field of vision, eliminating the burden on the eyes.&lt;/p>
&lt;h2 id="42-the-e-ink-display-paradigm-shift-dasung--boox">4.2 The E-Ink Display Paradigm Shift (Dasung &amp;amp; Boox)
&lt;/h2>&lt;p>For reading lengthy API references, technical books (PDFs), or code, the ultimate modern solution is using an &lt;strong>&amp;ldquo;E-Ink (electronic paper) display&amp;rdquo; as a secondary monitor&lt;/strong>.&lt;/p>
&lt;p>Unlike LCD or OLED, E-Ink does not have a self-emitting backlight. It displays text by applying voltage to move charged white and black pigment particles (such as titanium dioxide) inside capsules (electrophoresis), reflecting the ambient light.&lt;/p>
&lt;ul>
&lt;li>&lt;strong>Physical blue light emission: Zero&lt;/strong>&lt;/li>
&lt;li>&lt;strong>Flicker associated with PWM or refresh rates: Absolutely zero&lt;/strong>&lt;/li>
&lt;/ul>
&lt;p>By placing an E-Ink monitor like the &lt;strong>Dasung Paperlike&lt;/strong> series (e.g., 25.3 inches) or &lt;strong>Onyx Boox Mira&lt;/strong> vertically as a dedicated text sub-monitor, you can read documents with the exact same sensation as reading printed paper.
While it has the drawback of drawing delay (low refresh rate), if limited strictly to the &amp;ldquo;reading of static text&amp;rdquo; in a programming environment, there is no device on earth kinder to the eyes.&lt;/p>
&lt;hr>
&lt;h1 id="chapter-5-ergonomics-and-operational-rules">Chapter 5: Ergonomics and Operational Rules
&lt;/h1>&lt;p>No matter how excellent the hardware you assemble is, it is meaningless if the human operating it has the wrong posture or rules.&lt;/p>
&lt;h2 id="51-fluid-dynamics-of-dry-eyes-and-line-of-sight-angle">5.1 Fluid Dynamics of Dry Eyes and Line of Sight Angle
&lt;/h2>&lt;p>Dry eyes are not just a discomfort of &amp;ldquo;eyes feeling dry.&amp;rdquo; When the tear film on the surface of the cornea is destroyed, light diffuses irregularly, blurring your vision, which leads to a vicious cycle of further eye strain (overworking the ciliary muscles).
The evaporation rate of tears is proportional to the surface area of the eyeball exposed to the air (palpebral fissure area).&lt;/p>
&lt;p>The ideal line of sight angle $\theta$ for monitor placement is considered to be $15^\circ \sim 20^\circ$ downward from the horizontal line.
When the horizontal distance from the center of the monitor to the eye is $d$, and the height difference between the monitor center and eye level is $h$, the following trigonometric function holds true:&lt;/p>
$$ \tan \theta = \frac{h}{d} $$&lt;p>For example, if the distance $d$ to the monitor is $60 \text{ cm}$ (a typical desk environment), to set $\theta = 15^\circ$:&lt;/p>
$$ h = 60 \times \tan(15^\circ) \approx 60 \times 0.267 = 16.02 \text{ cm} $$&lt;p>In other words, &lt;strong>ideally, the center of the monitor should be about $16 \text{ cm}$ below eye level.&lt;/strong>
By directing your line of sight slightly downward, your upper eyelids naturally drop, reducing the exposed area of the eyeball, which can dramatically prevent tear evaporation. Install a monitor arm (like Ergotron) and accurately set this height down to the millimeter.&lt;/p>
&lt;h2 id="52-strict-adherence-to-and-automation-of-the-global-standard-20-20-20-rule">5.2 Strict Adherence to and Automation of the Global Standard &amp;ldquo;20-20-20 Rule&amp;rdquo;
&lt;/h2>&lt;p>The &amp;ldquo;20-20-20 Rule&amp;rdquo; is a recovery method for digital device eye strain recommended by the American Academy of Ophthalmology (AAO) and ophthalmologists worldwide.&lt;/p>
&lt;p>&lt;strong>&amp;ldquo;Every 20 minutes, look at something 20 feet (about 6 meters) away for 20 seconds.&amp;rdquo;&lt;/strong>&lt;/p>
&lt;p>Through this simple action, the extremely contracted ciliary muscles are forcibly relaxed, the crystalline lens thins out, and the focus adjustment function is reset.
Because programmers often lose track of time when entering a flow state, the engineer-like solution is to build a mechanism that automatically enforces this rule.
Below is an example of an extremely simple script using Python&amp;rsquo;s &lt;code>tkinter&lt;/code> that forcibly displays a popup every 20 minutes.&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre tabindex="0" class="chroma">&lt;code>&lt;span class="lnt"> 1
&lt;/span>&lt;span class="lnt"> 2
&lt;/span>&lt;span class="lnt"> 3
&lt;/span>&lt;span class="lnt"> 4
&lt;/span>&lt;span class="lnt"> 5
&lt;/span>&lt;span class="lnt"> 6
&lt;/span>&lt;span class="lnt"> 7
&lt;/span>&lt;span class="lnt"> 8
&lt;/span>&lt;span class="lnt"> 9
&lt;/span>&lt;span class="lnt">10
&lt;/span>&lt;span class="lnt">11
&lt;/span>&lt;span class="lnt">12
&lt;/span>&lt;span class="lnt">13
&lt;/span>&lt;span class="lnt">14
&lt;/span>&lt;span class="lnt">15
&lt;/span>&lt;span class="lnt">16
&lt;/span>&lt;span class="lnt">17
&lt;/span>&lt;span class="lnt">18
&lt;/span>&lt;span class="lnt">19
&lt;/span>&lt;span class="lnt">20
&lt;/span>&lt;span class="lnt">21
&lt;/span>&lt;span class="lnt">22
&lt;/span>&lt;span class="lnt">23
&lt;/span>&lt;span class="lnt">24
&lt;/span>&lt;span class="lnt">25
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre tabindex="0" class="chroma">&lt;code class="language-python" data-lang="python">&lt;span class="line">&lt;span class="cl">&lt;span class="kn">import&lt;/span> &lt;span class="nn">time&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="kn">import&lt;/span> &lt;span class="nn">tkinter&lt;/span> &lt;span class="k">as&lt;/span> &lt;span class="nn">tk&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="kn">from&lt;/span> &lt;span class="nn">tkinter&lt;/span> &lt;span class="kn">import&lt;/span> &lt;span class="n">messagebox&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="k">def&lt;/span> &lt;span class="nf">remind_20_20_20&lt;/span>&lt;span class="p">():&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="c1"># Hide the main window&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="n">root&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="n">tk&lt;/span>&lt;span class="o">.&lt;/span>&lt;span class="n">Tk&lt;/span>&lt;span class="p">()&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="n">root&lt;/span>&lt;span class="o">.&lt;/span>&lt;span class="n">withdraw&lt;/span>&lt;span class="p">()&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="k">while&lt;/span> &lt;span class="kc">True&lt;/span>&lt;span class="p">:&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="c1"># Wait for 20 minutes (1200 seconds)&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="n">time&lt;/span>&lt;span class="o">.&lt;/span>&lt;span class="n">sleep&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="mi">20&lt;/span> &lt;span class="o">*&lt;/span> &lt;span class="mi">60&lt;/span>&lt;span class="p">)&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="c1"># Display a warning dialog in the foreground&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="n">messagebox&lt;/span>&lt;span class="o">.&lt;/span>&lt;span class="n">showinfo&lt;/span>&lt;span class="p">(&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="n">title&lt;/span>&lt;span class="o">=&lt;/span>&lt;span class="s2">&amp;#34;20-20-20 Rule&amp;#34;&lt;/span>&lt;span class="p">,&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="n">message&lt;/span>&lt;span class="o">=&lt;/span>&lt;span class="s2">&amp;#34;Please look away from the screen and stare at something at least 6 meters away for 20 seconds!&lt;/span>&lt;span class="se">\n&lt;/span>&lt;span class="s2">(To relax your ciliary muscles)&amp;#34;&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="p">)&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="c1"># 20 seconds for relaxation&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="n">time&lt;/span>&lt;span class="o">.&lt;/span>&lt;span class="n">sleep&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="mi">20&lt;/span>&lt;span class="p">)&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="k">if&lt;/span> &lt;span class="vm">__name__&lt;/span> &lt;span class="o">==&lt;/span> &lt;span class="s1">&amp;#39;__main__&amp;#39;&lt;/span>&lt;span class="p">:&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="c1"># Run in the background&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> &lt;span class="n">remind_20_20_20&lt;/span>&lt;span class="p">()&lt;/span>
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>By registering such a script at startup or running it via the OS standard task scheduler/Cron, you can integrate a mandatory recovery cycle into your daily life.&lt;/p>
&lt;hr>
&lt;h1 id="conclusion-eye-strain-countermeasures-as-an-investment-in-the-future">Conclusion: Eye Strain Countermeasures as an Investment in the Future
&lt;/h1>&lt;p>Our careers as software engineers will last for decades. What supports that career is not an expensive keyboard or the latest CPU, but undeniably our own &amp;ldquo;eyes&amp;rdquo; and &amp;ldquo;brain.&amp;rdquo;&lt;/p>
&lt;ol>
&lt;li>&lt;strong>Understand the physical load of light energy ($E = hc/\lambda$) and focus adjustment.&lt;/strong>&lt;/li>
&lt;li>&lt;strong>Introduce a flicker-free (DC dimming) and high refresh rate monitor.&lt;/strong>&lt;/li>
&lt;li>&lt;strong>Optimize the relative contrast of the environment with bias lighting such as a ScreenBar.&lt;/strong>&lt;/li>
&lt;li>&lt;strong>Consider an E-Ink monitor as the ultimate text viewing device.&lt;/strong>&lt;/li>
&lt;li>&lt;strong>Create an optimal line of sight angle based on $\tan \theta = h/d$ using a monitor arm, and systemize the &amp;ldquo;20-20-20 Rule.&amp;rdquo;&lt;/strong>&lt;/li>
&lt;/ol>
&lt;p>While these measures may involve temporary expenses and effort, they are arguably the most cost-effective &amp;ldquo;technical investments&amp;rdquo; to extend the healthy lifespan of your eyes and maximize your lifelong productivity and QOL (Quality of Life). Reevaluate your development environment right now and implement some compassion for your eyes.&lt;/p></description></item></channel></rss>