Materials for optical and electronic devices