In all Mac programs, accented letters are just a few keys away.
For letters with acute accents (like á), press Option-e. Release both and type your letter, or Shift and your letter for a capital.
For ñ, press Option-n. Release both and press n again, or Shift-N for a capital Ñ.