5

On a high DPI screen, lines in Xfig are very thin. Is it possible to scale the lines, or the entire Xfig UI?

Note that I don't want to scale the entire desktop. Other application UIs are legible on high DPI screens.

Perhaps a Wayland compositor can scale an individual window?

3 Answers 3

5

Method that I used in the end:

  • Run Xfig in its own desktop under TigerVNC server.

  • Connect to the VNC server with a VNC client that allows scaling.

To simplify the process, I created a tool to run arbitrary applications scaled up, Vncdesk. A simple command such as vncdesk 2 starts the server and connects a viewer. Closing the application or the viewer shuts down the VNC server:

Screenshot showing original and scaled app

An alternative could be running each application window in its own VNC viewer, which is the goal of experimental x11vnc -appscale.

1

I'm now using an Apple 32-inch "Pro Display XDR" monitor on a macOS system with Xquartz in full resolution (starting it with full-screen mode enabled using xrander -s 6016x3384), and Xfig is one of the few apps that so far still refuses all attempts to get even its menu fonts to resize relative to the screen resolution.

However a quick and dirty hack on macOS with Xquartz in full-screen full-res mode is to open Xfig in the top-left corner of the full-res screen, then switch back to macOS (by exiting full-screen mode), then back to Xquartz again but without changing the resolution with xrandr (i.e. just use the shortcut or menu to turn full-screen back on). Window decorations and window manager fonts will be scaled outrageously large of course, as now you can see just the top-left 1/4 of your Xquartz screen scaled to full-screen size, but you'll see Xfig clearly readable and usable in scaled mode.

This of course works for any application that is stuck in the dark ages of pixel-based layout and sizing.

Now if only macOS itself would run with the true full resolution of this display!

0

TL;DR Start another X server, change its resolution, use XFig in the new, lowish DPI environment.


If you don't mind switching between different X sessions, this works for me

  1. run xrandr
    $ xrandr Screen 0: minimum 320 x 200, current 2160 x 1440, maximum 16384 x 16384 eDP connected primary 2160x1440+0+0 (normal left inverted right x axis y axis) 296mm x 197mm 2160x1440 60.00*+ 1920x1200 60.00 1920x1080 60.00 1600x1200 60.00 1680x1050 60.00 1280x1024 60.00 1440x900 60.00 1280x800 60.00 1280x720 60.00 1024x768 60.00 800x600 60.00 640x480 60.00 HDMI-A-0 disconnected (normal left inverted right x axis y axis) DisplayPort-0 disconnected (normal left inverted right x axis y axis)
    and choose a lesser resolution.
  2. Create an executable
     $ echo 'xrandr -s 1600x1200' > ~/bin/startxfig $ echo 'xfig -option 1 ... -option n -geometry 1600x1200' >> ~/bin/startxfig $ chmod +x ~/bin/startxfig 
  3. Activate a virtual console, e.g., CtrlAltF1, login in the virtual console and give the command
    $ startx xterm -e /home/username/bin/startxfig -- :2
    to have a full screen, reasonably scaled XFig. When you exit XFig, the startxfig script returns and first the xterm and next the X server exit gracefully.
  4. To switch to & from my usual session and the scaled-up XFig I use CtrlAltF1 and CtrlAltF2, ymmv in the sense that you may need different function keys.

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.