|
1 | | -*gui_x11.txt* For Vim version 7.4. Last change: 2016 Apr 08 |
| 1 | +*gui_x11.txt* For Vim version 7.4. Last change: 2016 Aug 21 |
2 | 2 |
|
3 | 3 |
|
4 | 4 | VIM REFERENCE MANUAL by Bram Moolenaar |
@@ -430,6 +430,9 @@ These are the different looks: |
430 | 430 | GNOME is compiled with if it was found by configure and the |
431 | 431 | --enable-gnome-check argument was used. |
432 | 432 |
|
| 433 | +Note: Avoid use of --enable-gnome-check with GTK+ 3 GUI build. The |
| 434 | +functionality mentioned above is consolidated in GTK+ 3. |
| 435 | + |
433 | 436 |
|
434 | 437 | GNOME session support *gui-gnome-session* *gnome-session* |
435 | 438 |
|
@@ -466,39 +469,52 @@ continues on Yzis: https://github.com/chrizel/Yzis. |
466 | 469 | ============================================================================== |
467 | 470 | 8. Compiling *gui-x11-compiling* |
468 | 471 |
|
469 | | -If using X11, Vim's Makefile will by default first try to find the necessary |
470 | | -GTK+ files on your system. If the GTK+ files cannot be found, then the Motif |
471 | | -files will be searched for. Finally, if this fails, the Athena files will be |
472 | | -searched for. If all three fail, the GUI will be disabled. |
| 472 | +If using X11, Vim's configure will by default first try to find the necessary |
| 473 | +GTK+ files on your system. When both GTK+ 2 and GTK+ 3 are available, GTK+ 2 |
| 474 | +will be chosen unless --enable-gui=gtk3 is passed explicitly to configure. |
| 475 | + |
| 476 | +If the GTK+ files cannot be found, then the Motif files will be searched for. |
| 477 | +Finally, if this fails, the Athena files will be searched for. If all three |
| 478 | +fail, the GUI will be disabled. |
| 479 | + |
| 480 | +For GTK+, Vim's configuration process uses pkg-config(1) to check if the |
| 481 | +GTK+ required for a specified build is properly installed and usable. |
| 482 | +Accordingly, it is a good idea to make sure before running configure that |
| 483 | +your system has a working pkg-config together with the .pc file of the |
| 484 | +required GTK+. For that, say, run the following on the command line to see if |
| 485 | +your pkg-config works with your GTK+ 2: > |
| 486 | +
|
| 487 | + $ pkgconfig --modversion gtk+-2.0 |
473 | 488 |
|
474 | | -For GTK+, Vim's configuration process requires that GTK+ be properly |
475 | | -installed. That is, the shell script 'gtk-config' must be in your PATH, and |
476 | | -you can already successful compile, build, and execute a GTK+ program. The |
477 | | -reason for this is that the compiler flags (CFLAGS) and link flags (LDFLAGS) |
478 | | -are obtained through the 'gtk-config' shell script. |
| 489 | +Replace gtk+-2.0 with gtk+-3.0 for GTK+ 3. If you get the correct version |
| 490 | +number of your GTK+, you can proceed; if not, you probably need to do some |
| 491 | +system administration chores to set up pkg-config and GTK+ correctly. |
479 | 492 |
|
480 | | -If you want to build with GTK+ 2 support pass the --enable-gtk2-check argument |
481 | | -to ./configure. Optionally, support for GNOME 2 will be compiled if the |
482 | | ---enable-gnome-check option is also given. |
| 493 | +The GTK+ 2 GUI is built by default. Therefore, you usually don't need to pass |
| 494 | +any options such as --enable-gui=gtk2 to configure and build that. |
| 495 | + |
| 496 | +Optionally, the GTK+ 2 GUI can consolidate the GNOME 2 support. This support |
| 497 | +is enabled by passing --enable-gnome-check to configure. |
| 498 | + |
| 499 | +If you want to build the GTK+ 3 GUI, you have to pass --enable-gui=gtk3 |
| 500 | +explicitly to configure, and avoid passing --enable-gnome-check to that, as |
| 501 | +the functionality of the GNOME 2 support has already been consolidated in |
| 502 | +GTK+ 3. |
483 | 503 |
|
484 | 504 | Otherwise, if you are using Motif or Athena, when you have the Motif or Athena |
485 | 505 | files in a directory where configure doesn't look, edit the Makefile to enter |
486 | 506 | the names of the directories. Search for "GUI_INC_LOC" for an example to set |
487 | 507 | the Motif directories, "CONF_OPT_X" for Athena. |
488 | 508 |
|
489 | 509 | *gui-x11-gtk* |
490 | | -At the time of this writing, GTK+ version 1.0.6 and 1.2 are outdated. It |
491 | | -is suggested that you use GTK 2. The GTK 1 support will most likely be |
492 | | -dropped soon. |
493 | | - |
494 | | -For the GTK+ 2 GUI, using the latest release of the GTK+ 2.0 or GTK+ 2.2 |
495 | | -series is recommended. |
496 | | - |
497 | | -Lastly, although GTK+ has supposedly been ported to the Win32 platform, this |
498 | | -has not been tested with Vim and is also unsupported. Also, it's unlikely to |
499 | | -even compile since GTK+ GUI uses parts of the generic X11 code. This might |
500 | | -change in distant future; particularly because getting rid of the X11 centric |
501 | | -code parts is also required for GTK+ framebuffer support. |
| 510 | +Currently, Vim supports both GTK+ 2 and GTK+ 3. |
| 511 | + |
| 512 | +The GTK+ 2 GUI requires GTK+ 2.2 or later. |
| 513 | + |
| 514 | +Although the GTK+ 3 GUI is written in such a way that the source code can be |
| 515 | +compiled against all versions of the 3.x series, we recommend GTK+ 3.10 or |
| 516 | +later because of its substantial implementation changes in redraw done at |
| 517 | +that version. |
502 | 518 |
|
503 | 519 | *gui-x11-motif* |
504 | 520 | For Motif, you need at least Motif version 1.2 and/or X11R5. Motif 2.0 and |
|
0 commit comments