Coder Social home page Coder Social logo

kotoba's Introduction

Kotoba

Quickly search the built-in iOS dictionary to see definitions of words. Collect words you want to remember.

Installation (iPhone or iPad)

Note: An Apple Developer account is required.

  1. Clone or download Kotoba from GitHub.
  2. Open code/Kotoba.xcodeproj in Xcode.
  3. Select the Kotoba project file in Navigator, select the "Kotoba" target, then select the "Signing & Capabilities" tab.
  4. Change the "Team" to your Apple Developer account team.
  5. Change the "Bundle Identifier" to com.yourdomain.Kotoba.
  6. Change the "App Groups" to groups.com.yourdomain.Kotoba by adding yours, and deleting the current one.
  7. Select the "ShareExtension" target, and repeat the three steps above.
  8. Open the "Devices and Simulators" window (Shift-Cmd-2) and confirm your device is connected. If not, connect it via USB.
  9. Product > Run.

How to Use

  1. Tap "Add a new word".
  2. Type or dictate the word you want to look up, and hit the Search key.
  3. The iOS system dictionary view will slide up, showing you the definition of the word.
  4. If no definition appears, you may not have the right dictionaries installed. Tap "Manage" in the bottom-left of the screen, and download the appropriate dictionaries.
  5. Tap Done, and you're back at the main screen. The word you just looked up is added to the word history list.
  6. You can delete words from the list by swiping left and tapping "Delete".

Why Kotoba?

The original idea came from @gruber in a DM to @DFstyleguide:

Ever find a good iPhone dictionary app?

Best I’ve found is Terminology, but it’s so complicated I usually just fire up Vesper and use the system “Define” service.

The system one is good; and it’s perfect for when I’m reading in an app. I find it fiddly to use though when I’m reading a printed book.

I want:

  1. Open dictionary app.
  2. Start typing word to look up.
  3. Read definition.

Instead I have to:

  1. Open Vesper
  2. Open a note
  3. Type the word I’m looking for
  4. Select the word, tap Define
  5. Read definition.
  6. Close dictionary and delete the word from my note.

Development Status

Kotoba is in a bare-bones state, with just enough functionality to be useful.

As far as I know, it works fine. But if you find any bugs, or have suggestions for improvement, please raise an issue on GitHub. Any feedback is heartily welcome.

Why Open-Source?

Look, ladies and gents, you are much smarter than I. I am a working developer, but Swift/iOS is not my day job. I made this open-source for two reasons:

  • Honestly, I suspected Kotoba wouldn't be approved for the App Store. If it's open-source, the Xcode-savvy can at least install it on their personal devices.
  • If smarter, more experienced Swift developers can suggest improvements or fix my bugs, I will learn from them.

Which is a nice segue to... how to contribute

kotoba's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

kotoba's Issues

Ignore multiline pasteboard text at launch

The new feature added in #41 to automatically detect text on the pasteboard, and offer to use it as a search, should ignore pasteboard text that contains newline characters, as it is unlikely to be useful as a word search.

Export word list

Would you consider integrating an export function into the app?

In my own crude way, I tried to accomplish this by downloading the app's container via Xcode and browsing through the files, but to no avail. If there ever comes a point where the app is no longer supported, I wouldn't want the words I've accumulated to disappear along with it.

I found the app based on @gruber's recommendation and I've been using it incessantly ever since. Your work is much appreciated. Thank you.

Hard to touch done button when done

Please use UINavigationController to push the UIReferenceLibraryViewController, instead of modally present. Considering current iPhone's screen can be up to 5.8 inch, the done button is really hard to reach.

in UIViewController+Dictionary.swift
'''
navigationController?.pushViewController(dictionaryViewController, animated: true)
// present(dictionaryViewController, animated: true, completion: nil)
""

So that we can get back to main view controller by swiping

Thank you.

Search not triggered on autocorrect

  1. Disable QuickType.
  2. Mis-type a word in a way that autocorrect can fix.
  3. Tap Search button on keyboard.

Should search for autocorrected word.

Search doesn't happen.

Force Apple Dictionary when none are set up

Instead of the annoying prompt upon first search to remind the user to set up their iOS dictionaries, use @danielpunkass's clever hacks to inspect the currently-installed set of dictionaries, and just use the default Apple Dictionary if there are none.

This is tangentially related to #32. Consider implementing together.

Add tests for clipboard behaviour

#41 added a new feature to use the pasteboard text as a search.

The new feature breaks UITests if there is something on the pasteboard before launch, and the new feature itself is missing tests.

For now, I have added code in the UITests to clear the pasteboard in setup, but this is not ideal. The pasteboard contents should not be destroyed by the test, in case there was something important there.

Replace `NSUserDefaults` with something better

NSUserDefaults was used as a quick temp solution for persistence in the beginning, and I never got around to replacing it with something better.

Candidate replacements, off the top of my head:

  • Core Data
  • Realm
  • a plain ol' flat file
  • something else I've never heard of

(Unfortunately, since Apple won't accept Kotoba for the App Store, CloudKit is off the table, I guess.)

Typing too slow

@gruber:

BTW, just got around to downloading and installing Dictionary.app. Was intolerably slow to type for me, but changing the Timer delay from 0.5 to 1.0 did the trick.

Searches are slow on iOS 13

Hi,

when i type in a word and then click Search, Kotoba reacts rather slow and slugish, when run on iOS 13. Any updates for iOS 13 in sight (i am not a developer which could fix this)?

Thanks for such a useful App!

Bigger search bar

@gruber

can we make the search bar and text bigger? More like 20pt or 24pt or something instead of 16? Why not since it’s the only input?
I tried poking around the storyboard in Xcode but don’t see any way to change that there.

"Done" button doesn't do anything

One of a slew of rough edges caused by shoehorning UIReferenceLibraryViewController...

The built-in iOS dictionary view has its own nav bar, with a "Done" button for dismissing it. Since we don't present the dictionary view modally, the "Done" button does nothing.

Multiple lists

e.g. to keep foreign language learning vocab lists separate

Allow import of .dictionary files

It would be immensely useful to be able to import and use custom made .dictionary files (same as used in macOS Dictionary app). One could then utilize dictionaries and thesaurus outside of Apple-provided languages, specific to a profession or other needs, offline.

Show number of words in history

  • Show number of words in history screen somewhere
  • Show number of words when exporting
  • Localise "n words" text
  • Pluralise "1 word" properly

Tests failing

Fix unit/UI tests that are failing after 2.0 enhancements.

Sync across devices

This is a redux of #11, to enable syncing via iCloud Drive or other cloud services. If the user can select a save location of their choice via the Files API, and Kotoba can access/update that location without prompting the user every time, then it doesn't need iCloud access (read: doesn't need to be an App Store app).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.