Got Questions? Get Answers.
Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
Pasting a symbol into a powerpoint slide from MATLAB

Subject: Pasting a symbol into a powerpoint slide from MATLAB

From: Keane

Date: 13 Aug, 2009 18:13:03

Message: 1 of 3

I'm trying to create some Powerpoint slides from within matlab and can do the various things like create a title, new slide, etc... When I create the title, I require being able to write out a greek symbol, like alpha, beta, or lambda. When I try adding the symbol character, a box appears (symbol shows as a box in matlab too). A snippet of the code I'm using is below:


ppt = actxserver('PowerPoint.Application')
ppt.Visible = 1
thisPresentation = ppt.Presentations.Open(file)

text_here = ['my text with symbol ' char(value for greek symbol)]

thisSlide = ppt.ActiveWindow.View.Slide
text_box.TextFrame.TextRange.Text = text_here
text_box.TextFrame.TextRange.FontSize = 24

I've tried inserting various ascii/utf values for symbols, but not all will show up in matlab. In the matlab slide, I'll get a text box with 'my text with symbol ' and a box after. Is it not possible to add a non-standard symbol using this method? Any simple ideas on getting a greek symbol into the text from matlab?

Thanks,

Keane Gonzalez

Subject: Pasting a symbol into a powerpoint slide from MATLAB

From: Yair Altman

Date: 14 Aug, 2009 13:18:18

Message: 2 of 3

"Keane " <keane_gonzalezREMOVE@hotmail.com> wrote in message <h61l3f$atj$1@fred.mathworks.com>...
> I'm trying to create some Powerpoint slides from within matlab and can do the various things like create a title, new slide, etc... When I create the title, I require being able to write out a greek symbol, like alpha, beta, or lambda. When I try adding the symbol character, a box appears (symbol shows as a box in matlab too). A snippet of the code I'm using is below:
>
>
> ppt = actxserver('PowerPoint.Application')
> ppt.Visible = 1
> thisPresentation = ppt.Presentations.Open(file)
>
> text_here = ['my text with symbol ' char(value for greek symbol)]
>
> thisSlide = ppt.ActiveWindow.View.Slide
> text_box.TextFrame.TextRange.Text = text_here
> text_box.TextFrame.TextRange.FontSize = 24
>
> I've tried inserting various ascii/utf values for symbols, but not all will show up in matlab. In the matlab slide, I'll get a text box with 'my text with symbol ' and a box after. Is it not possible to add a non-standard symbol using this method? Any simple ideas on getting a greek symbol into the text from matlab?
>
> Thanks,
>
> Keane Gonzalez

You should set the Powerpoint TextRange font to a font that includes these ASCII codes - not all fonts do.

Yair Altman
http://UndocumentedMatlab.com
 

Subject: Pasting a symbol into a powerpoint slide from MATLAB

From: Keane

Date: 27 Aug, 2009 21:13:04

Message: 3 of 3

Yair,
  Thanks for the font hint. I've tried multiple fonts and most of the mainstream fonts seem to have the greek letters support (except for some of those obscure fonts). I can print out some characters by just sending the raw UTF code, like:

text_to_show = [ 'test line here ' 188 ' symbol should have printed']

For some odd reason, the greek symbols just will not show up. Thanks for the help though.

Keane


"Yair Altman" <altmanyDEL@gmailDEL.comDEL> wrote in message <h63o6q$7qr$1@fred.mathworks.com>...
> "Keane " <keane_gonzalezREMOVE@hotmail.com> wrote in message <h61l3f$atj$1@fred.mathworks.com>...
> > I'm trying to create some Powerpoint slides from within matlab and can do the various things like create a title, new slide, etc... When I create the title, I require being able to write out a greek symbol, like alpha, beta, or lambda. When I try adding the symbol character, a box appears (symbol shows as a box in matlab too). A snippet of the code I'm using is below:
> >
> >
> > ppt = actxserver('PowerPoint.Application')
> > ppt.Visible = 1
> > thisPresentation = ppt.Presentations.Open(file)
> >
> > text_here = ['my text with symbol ' char(value for greek symbol)]
> >
> > thisSlide = ppt.ActiveWindow.View.Slide
> > text_box.TextFrame.TextRange.Text = text_here
> > text_box.TextFrame.TextRange.FontSize = 24
> >
> > I've tried inserting various ascii/utf values for symbols, but not all will show up in matlab. In the matlab slide, I'll get a text box with 'my text with symbol ' and a box after. Is it not possible to add a non-standard symbol using this method? Any simple ideas on getting a greek symbol into the text from matlab?
> >
> > Thanks,
> >
> > Keane Gonzalez
>
> You should set the Powerpoint TextRange font to a font that includes these ASCII codes - not all fonts do.
>
> Yair Altman
> http://UndocumentedMatlab.com
>

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us