Delphi uses large icons to compile programs

Source: Internet
Author: User

In Windows Vista, Windows7 above the Windows system can support large icon display, but Delphi compiled by the program can only display the 32x32 icon, which makes the Delphi compiler program looks very unprofessional. The following will be the Delphi compiled large-icon program to share the method.

To use large icon compilation, first prepare a 256x256 icon image.

Use the icon editing software, such as IconWorkshop open your ICO file, create a new 256x256 True color icon and import your picture file into the icon. After saving the icon, copy the icon file to your project directory, assuming Mainico.ico, then build a mainico.rc file under your project and enter the text inside:

Mainicon ICON Mainico.ico

Open a command-line window, switch the directory to your project directory, enter the command RC mainico.rc, press ENTER to execute, then in your project directory will generate a mainico.res file.

To open your project in Delphi, select the menu Project->view Source, add a line {$R mainico.res} under {$R *.res}, and then compile the program.

The Windows system caches the icon, so you may not see the effect as soon as you compile it, and you can copy the compiled program to another place to see if it becomes a large icon.

The RC command is called by Microsoft Windows Resource Compiler

Http://bcoder.com/delphi/compile-program-with-large-icon-in-delphi

Delphi uses large icons to compile programs

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.