Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Live Code Editor

edited November 8 in Code Sharing Posts: 22

MOVED HERE

Simple live code editor

(can also be used for text editing)

Features:

  • Multiple lines input and output
  • Cursor support
  • Customizable Cursor
  • Tap or drag anywhere to navigate cursor
  • Double tap anywhere and drag to select text
  • CUT / COPY / PASTE selected text at/to any position (only for hardware keyboard)
  • Hardware keyboard to navigate cursor
  • Jump and teleport cursor to any position

To be added:

  • Fix cursor misalignment at certain font sizes
  • Custom text wrapper
  • Scrolling action
  • Ability to CREATE NEW / SAVE / LOAD text document
  • On screen shortcuts / menu to perform CUT / COPY / PASTE

Download the Codea Project below in ZIP (not yet tested on Codea for iPhone)
Also screenshot on iPadOS attached below...

Comments

  • Update v0.3

    Added features:

    • On screen shortcuts / menu to perform CUT / COPY / PASTE
    • Selecting text is easier with text magnifier

    To do:

    • Scrolling action
    • Custom text wrapper
    • Fix misaligned cursor at certain font sizes
  • edited October 12 Posts: 1,351

    @Simeon, @marcelliino - ran your excellent program staggering effects and editor is amazing. But, I ran this by downloading your zip file to my downloads and running from there. The project was unzipped in the download folder but ran from there OK. On returning to the editor - no new project. So ran again from download folder at which point Codea crashed.

    Do you have to place zipped projects in the Codea documents folder and unzip there? Or just copy the unzipped project across?

    Edit: answered my own question, copied unzipped project to Codea folder and icon appeared in project list. Interesting though, project ran from external folder initially but then failed on re-run.

  • dave1707dave1707 Mod
    Posts: 7,836

    @Bri_G When I did it, it opened in Codea and ask if I wanted to load it. Once loaded, it was in my Codea projects.

  • Posts: 1,351

    @dave1707 - must have missed that, I selected downloads to unzip into thinking that when you unzipped it would request where to unzip to - but it used the current folder. With it running from downloads first time I thought - great, can store projects remotely, but then hit the failure second time.

  • dave1707dave1707 Mod
    Posts: 7,836

    @Bri_G Apparently iOS 13 isn’t doing it the easy way. I used to long press on the zip file and select share. It then gave me the option to open it in Codea. That doesn’t seem to work anymore.

  • edited October 12 Posts: 1,351

    @dave1707 - ohhh how I love progress!!!! Apparently The fruit is under pressure from iOS 13 and Catalina at the moment. Reports suggest they were rushed to meet the annual launch of the next best thing. Commercial vs technical war? They will sort out the problems - they have a good team.

  • dave1707dave1707 Mod
    Posts: 7,836

    @Bri_G So far I haven’t figured out how to get Codea to show up in the list of apps to receive the file.

  • Posts: 1,351

    @dave1707 - just tapped on the app in my download folder, it loaded and ran Codea then. Or, long press on the icon to get the menu of options up, scroll top set of icons to more ... then down the resultant menu to find Codea. Pheeew good job it wasn’t buried in menus!!!!

  • dave1707dave1707 Mod
    Posts: 7,836

    @Bri_G If I long press on the zip file above, then select share, and scroll the top list to get to the more selection, I don’t have Codea in the list of choices.

  • edited October 12 Posts: 1,351

    @dave1707 - it’s on mine. Is there a mechanism for adding it, or is there a setting in the system app for Codea to be added?

    By the way I am on 3.0.1 (188) and iOS 13.1.

    Edit: just noticed you pressed on the zip file. Try tapping the zip to save project file locally, then check out the above tap or long press options on the unzipped project file in the downloads folder.

  • dave1707dave1707 Mod
    Posts: 7,836

    @Bri_G I’m on 3.0.1 (188) and iOS 13.1.2 . I tried the download and it put the file in a download folder. I long pressed the file there, did share, and was given the option to download to Codea. It would be nice if you didn’t have to mess around so much because of an iOS update.

  • edited October 12 Posts: 1,351

    @dave1707 - I think this is down to the file type issue. iOS will treat zip file types in one way and Codea files will be tied to Codea as parent app. Perhaps we need a new filetype for zipped Codea files, zipdea or codip files which could unzip directly into the documents folder then directly install the project into Codea.
    :
    As an aside I have edited this text three times because I added an emoji inline after codip and the rest of the line was deleted. Is this normal, or do you have to use markdown? :'(

    Edit - or use the emoji insert from the editing window - doh - limits the options a bit!!!

  • dave1707dave1707 Mod
    Posts: 7,836

    @Bri_G I guess the emoji from the editing window. I know if you add an emoji in a program listing in the forum, anything after it doesn’t show.

  • Posts: 1,351

    @dave1707 - emojis inline - yeah found out the hard way. Now upgrading to 13.1.2 so a whole new range of experiences to encounter.

  • edited October 13 Posts: 22

    @Bri_G Opening/Importing Codea archive in iOS 13:

    1. Long press the zip file
    2. Choose share
    3. Tap Open in Codea
    4. And tap import
  • dave1707dave1707 Mod
    Posts: 7,836

    @marcelliino For some reason I haven’t figured out yet, Codea doesn’t show as one of the icons and doesn’t show in the list when more is selected. I’m on the latest version of everything. Don’t know why Codea isn’t being recognized.

  • edited October 13 Posts: 1,351

    @marcelliino - thanks for the feedback, tried the long press and didn’t find the icon in share, but I did in the ... more menu. @dave1707 - I think it depends on how many apps you have installed, the more menu holds the excess so no large icon at top. Funny though, Codea is alphabetically closer to being on the top and Codea is by far my most used app. So what is the basis for selection of the large icons in the top menu - and can you modify that selection process. I find the multiple option on iOS for file/app issues a pain - surely someone will simplify it - you know add a single consistent file system!!! Thanks again, image attached of share/menu.

  • @dave1707 @Bri_G You can add Codea to favorites list

    1. Tap more (...)
    2. Edit
    3. Add (+) Codea and drag to the top list
    4. Tap done

    Note: In iOS 13 this menu configuration is saved per apps (every app has their own favorites sharing list)

  • Posts: 1,351

    @marcelliino - thanks for the update - that’s a real gem. Will help me out in future and avoid a lot of confusion.

  • dave1707dave1707 Mod
    Posts: 7,836

    @marcelliino The problem is I don’t have Codea in the normal list or the MORE list when I do SHARE with the zip file. And I haven’t found a way to force Codea in the list. I tried on my other iPad that’s on iOS 12 and I no longer have Open in Codea on that one either. I went to a discussion that had a zip file that I shared with Codea previous and Codea is missing there too. It’s like once I updated to iOS 13 on the new iPad, the old one on iOS 12 is doing the same thing.

  • dave1707dave1707 Mod
    Posts: 7,836

    If I export a Codea project as a zip file and save it in Dropbox and select the zip file in Dropbox with export, it give me Codea as an option. So if I create a zip file, Codea shows as an option, but if I try someone else’s zip file, Codea doesn’t show. I had no problems before I updated to iOS 13.

  • Posts: 1,351

    @dave1707 - did you try someone else’s zip file before and after loading Codea? It could be if Codea is registered as present that it is added to the options.

  • dave1707dave1707 Mod
    edited October 13 Posts: 7,836

    @Bri_G Here’s a zip file that I tried to test with. If I put this file into a Codea folder in the Files app and long press on it, then Open in Codea shows in the share list. If I long press on the file from here, Codea doesn’t show in the share list. But it used to work from everywhere before I loaded iPadOS 13. If you long press on this file do you get the Open in Codea to show. So as far as I know, iPadOS 13 messed something up for me.

    00a1.zip 868B
  • Posts: 1,351

    @dave1707 - shared the file to Dropbox:Codea folder and Dropbox root and the iCloud downloads folder. All worked apart from the Dropbox root folder. Gave a sound project which incorporated the sound trace with the Codea icon on screen capture. Used the ... menu feature of sharing to load. Looks like it will work with all things Apple including application created paths like Dropbox:Apps/Codea. i.e. ones that have a local path folder in their documents folder.

  • Posts: 1,351

    @dave1707 - did notice that there seemed to be a naming issue with Dropbox or Dropbox refused to copy files. Also, used the suggestion by @marcelliino above and added Codea to my pre...more top menu - try that.

  • dave1707dave1707 Mod
    Posts: 7,836

    @Bri_G Here's what I figured out.

    If I long press on the 00a1.zip file above and select Share, Codea doesn’t show in the sliding list or in the More list. So I can’t do anything with Codea using the long press.

    If I tap the file 00a1.zip, I get the message Do you want to Download filename. I tap Download. I go into the Files app and look in the folder Downloads. I long press the file there and select Share. Open in Codea shows as the 2nd option. I tap on Open in Codea and Codea opens where I can import the file into Codea with no problems.

    Before I downloaded iPadOS 13, I used to be able to long press the zip file, select Share, select Open in Codea, and Codea would load with the import window. So Apple screwed up the simple download for me and now I have to go thru a lot more steps to load a zip file from the forum.

    So far I haven’t found a way to get Open in Codea to show using the long press on the zip file like I used to.

  • edited October 14 Posts: 1,351
    @dave1707 - can you add Codea to the ..more by using the suggestions section at the bottom?

    Edit: we've kinda monopolised this thread, as a mod can you set up a more meaningful thread and transfer this issue to it - Something like iPadOS issues.
  • dave1707dave1707 Mod
    Posts: 7,836

    @Bri_G I was thinking the same thing about us taking over this discussion, but I’m also wondering how many others are running into the same problem I am after the iOS update. Creating a zip file was an easy way to load large Codea projects for others to download. I can’t move everything in this discussion, but it might be easier for @marcelliino to start another discussion for his editor if he has another update. I can then rename this discussion for iPadOS 13 issues using Codea.

    I can’t find any way to add Codea to the list of apps. I also can’t find any info about how an app is selected to appear in the list. There are some apps in the list that have nothing to do with the file being used. If I long press the 00a1.zip file, why would I want to send it to Messages, or Messenger, or Reminders, or Facebook. Then if I select More, why is Notes and Twitter in the list. Those are some of the apps that show for me, but not Codea. I tried deleting some of the apps in the list thinking Codea might show up, but the list was just shorter and no Codea.

  • edited October 14 Posts: 1,351

    @dave1707 - you have no doubt seen which mentions the Share Sheet API - which I am sure the Codea team have included. Made me think - on your Codea settings in System what have you indicated as your storage location - mine is ‘On my iPad’ - is yours Dropbox?

  • dave1707dave1707 Mod
    Posts: 7,836

    @Bri_G My Codea storage is On my iPad. If I long press on my test zip file above (00a1.zip) and select Share, I get Air Drop, Mail, Dropbox, Messages, Reminders, Notes, Messenger, Facebook, and More. If I select More, I show everything I just listed plus Twitter. I’ve looked at everything I can find on the Share sheet, but I haven’t found any way to add an app that isn’t listed. In other words, Apple selects what they think you want but won’t let you add what you actually want. What do you get if you long press on 00a1.zip and select Share. I even turned everything off I could with the sliders when I selected More, but that didn’t change anything.

  • Posts: 1,351

    @dave1707 - interesting, just tried the long press/share and my share menu has completely changed. Codea is no longer on it. Only thing zi can think may have influenced it is I used my other iPad earlier today and the share menu is very small on that as I have only loaded a few apps. Do you use different iPads? It may be down to your account settings, one iPad settings may change if you use the same account on each iPad.

  • dave1707dave1707 Mod
    Posts: 7,836

    @Bri_G I do have several iPads on the same account, and they get used regularly. Not sure what can be changed to get Codea back in the list. If you figure something out, let me know. I’m still trying to find anything that might help.

Sign In or Register to comment.