EXCLUSIVE: Welsh actor Ioan Gruffudd is set to join Mel Gibson and Sean Penn in The Professor and the Madman, a film about James Murray, the 19th century professor who started to compile the Oxford English Dictionary.

Gruffudd will play the role of Henry Bradley, a particular and demanding philologist who helps Murray (played by Gibson) assemble words for the compilation of the Oxford Dictionary. Extremely officious and easily exasperated, Bradley’s attention to detail is exhausting but ultimately proves to be a great asset in the assembly of the dictionary.

Story is based on an adaptation of Simon Winchester’s bestselling novel The Professor and the Madman: A Tale of Murder, Insanity and the Making of the Oxford English Dictionary. It’s a passion project for Gibson, who’s been working to adapt the book for nearly two decades. Farhad Safinia, who wrote Gibson’s Apocalypto, is set to direct. John Boorman (Hope and Glory) and Todd Komarnicki (Sully) write the script with Safinia. Bruce Davey, Gibson’s longtime partner at Icon, is producing while Nicolas Chartier’s Voltage Pictures is on-board sell the title.

Gibson, who at one point was going to direct the film, will play the lead role of Murray with Penn playing Dr. W.C. Minor, who contributed thousands of entries to the ambitious literary project but who was also an inmate at an insane asylum.

Gibson is fresh off the back of Venice Film Festival hit Hacksaw Ridge, a World War II drama that stars Andrew Garfield as American Army Medic Desmond T. Doss, who served during the Battle of Okinawa and became the first Conscientious Objector to be awarded the Medal of Honor.

Gruffudd is known for his roles in the Fantastic Four franchise, Titanic and King Arthur. He recently wrapped Keep Watching, directed by Sean Carter. He is repped by ICM and Framework Entertainment.