Step back in time with the elegant source code for Photoshop 1.0

Adobe Photoshop logoThe Computer History Museum has made available the source code for the 1.0.1 version of Photoshop, as noticed by Slashdot. The image editing application is a staple of professional and amateur artists alike, and its ubiquity has led its name to be generalized in the same way as "kleenex," "xerox," and "google"—to edit an image is to "photoshop" it.

Though this early build of Photoshop lacks a lot of features present in the current Creative Suite version, it was still a powerful graphical editing utility when released back in 1990. Photoshop 1.0 was exclusively a Macintosh application, and the code is representative of the typical Mac coding tools of the era—it's a mixture of about 75 percent Pascal and 15 percent Motorola 68000 assembly language, with the rest of the code composed of data files.

Altogether, there are about 185,000 lines of code in 179 files. The code isn't quite complete, though, since it's missing the MacApp framework (which can't be included because it would have to be licensed from Apple).

Photoshop 1.0.1

The linked Computer History Museum page contains some commentary on the code from Grady Booch, chief scientist for Software Engineering at IBM Research Almaden:

Architecturally, this is a very well-structured system. There’s a consistent separation of interface and abstraction, and the design decisions made to componentize those abstractions – with generally one major type for each combination of interface and implementation — were easy to follow....

There are only a few comments in the version 1.0 source code, most of which are associated with assembly language snippets. That said, the lack of comments is simply not an issue. This code is so literate, so easy to read, that comments might even have gotten in the way....This is the kind of code I aspire to write.

Booch notes the code even contains easily identifiable references to Macintosh software architect Andy Hertzfeld's Thunderscan device, a clip-in scan head that could transform a dot matrix printer into an inexpensive (but slow) grayscale scanner.

Though Pascal and 68000 assembly aren't the modern coding tools of choice, there's tremendous value to be gained in studying beautiful code (see this Doom 3 source code critique for a more contemporary example). Lessons in structuring a program tend to transcend languages, and being able to define and solve computing problems in discrete, understandable steps with a minimum of cruft or kludging is something every developer should strive for.

The complete bundle is available for download at the Computer History Museum and is also mirrored on Github.

Source: Ars Technica

Tags: Adobe, graphics editors

Add comment

Your name:
Sign in with:
Your comment:

Enter code:

E-mail (not required)
E-mail will not be disclosed to the third party

Last news

Pokemon GO had the potential to net $1 billion a year
The report said that Hon Hai has invested about US$600 million in India
Market research firm IDC reports that in the third quarter of this year
Customers will only have to shell out 50% of the cost of their Galaxy S7 device
New flagship will launch in 2017
Patent hints at name of the upcoming Surface AIO
IBM, Globalfoundries and Samsung have chosen to use extreme ultraviolet (EUV) light to pattern transistors
Samsung Galaxy TabPro S - a tablet with the Windows-keyboard
The first Windows-tablet with the 12-inch display Super AMOLED
June 7, 2016 /
Keyboards for iOS
Ten iOS keyboards review
July 18, 2015 /
Samsung E1200 Mobile Phone Review
A cheap phone with a good screen
March 8, 2015 / 4
Creative Sound Blaster Z sound card review
Good sound for those who are not satisfied with the onboard solution
September 25, 2014 / 2
Samsung Galaxy Gear: Smartwatch at High Price
The first smartwatch from Samsung - almost a smartphone with a small body
December 19, 2013 /
HP Slate 7 is a 7-inch Android 4 Tablet PC with good sound
A cost-effective, 7-inch tablet PC from a renowned manufacturer
October 25, 2013 / 4

News Archive



Do you use microSD card with your phone?
or leave your own version in comments