Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

syntaxDefinitionMenu not working #11

Closed
eightbitme opened this Issue Aug 5, 2012 · 2 comments

Comments

Projects
None yet
2 participants

I can't seem to get syntaxDefinitionMenu to work, Im pretty new to objective-c, but I have it linked up to a menu item from MGSTextMenuController. Is there something else I have to do?

Owner

mugginsoft commented Aug 5, 2012

Hi

You are right. The syntaxDefinitionMenu does not get populated correctly.
MGSTextMenuController -buildSyntaxDefinitionsMenu calls SMLBasic -fetchAll to retrieve the syntax definitions.
-fetchAll though does nothing. This code is a relic from the original Smultron implementation.

The syntax definitions are actually loaded by MGSSyntaxController.
An array of syntax definition names is available from the MGSSyntaxController syntaxDefinitionNames property.

Using that array and the code from buildSyntaxDefinitionsMenu you should be able to construct your menu.

Regards

Jonathan Mitchell
Mugginsoft LLP

On 5 Aug 2012, at 11:37, eightbitme wrote:

I can't seem to get syntaxDefinitionMenu to work, Im pretty new to objective-c, but I have it liked up to a menu item from MGSTextMenuController. Is there something else I have to do?


Reply to this email directly or view it on GitHub:
#11

What would the be the best way to do that?

Jonathan Mitchell
mailto:reply@reply.github.com
6 August 2012 6:38 AM
Hi

You are right. The syntaxDefinitionMenu does not get populated correctly.
MGSTextMenuController -buildSyntaxDefinitionsMenu calls SMLBasic
-fetchAll to retrieve the syntax definitions.
-fetchAll though does nothing. This code is a relic from the original
Smultron implementation.

The syntax definitions are actually loaded by MGSSyntaxController.
An array of syntax definition names is available from the
MGSSyntaxController syntaxDefinitionNames property.

Using that array and the code from buildSyntaxDefinitionsMenu you
should be able to construct your menu.

Regards

Jonathan Mitchell
Mugginsoft LLP


Reply to this email directly or view it on GitHub:
#11 (comment)

@mugginsoft mugginsoft closed this Sep 27, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment