This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.support.design.widget.Snackbar; | |
import android.view.View; | |
import android.widget.TextView; | |
import android.view.View.OnClickListener; | |
import android.graphics.drawable.Drawable; | |
import android.widget.ImageView; | |
import android.graphics.drawable.Icon; | |
import android.graphics.Bitmap; | |
public class Snacker |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.support.design.widget.Snackbar; | |
import android.view.View; | |
import android.widget.TextView; | |
import android.view.View.OnClickListener; | |
import android.graphics.drawable.Drawable; | |
import android.widget.ImageView; | |
import android.graphics.drawable.Icon; | |
import android.graphics.Bitmap; | |
public class Snacker |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.content.res.*; | |
import java.util.*; | |
import android.content.*; | |
public class InnerReader | |
{ | |
public static String readText(Context context, int resId){ | |
StringBuilder sb = new StringBuilder(); | |
Scanner reader = new Scanner(context.getResources().openRawResource(resId)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.app.*; | |
import android.content.*; | |
import android.os.*; | |
import java.util.*; | |
public class MultiChoiceListDialog extends DialogFragment { | |
private String title; | |
private String[] choices; | |
private ArrayList<String> selectedItems; | |
private OnDismissListener listener; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.app.*; | |
import android.content.*; | |
import android.os.*; | |
import java.util.*; | |
public class ListDialog extends DialogFragment { | |
private String title; | |
private String[] choices; | |
private OnDismissListener listener; | |
private FragmentManager fragmentManager; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.app.*; | |
import android.os.*; | |
import android.content.*; | |
public class MyDialog extends DialogFragment { | |
public static final int YES = 1, NO = 0, CANCEL = 2; | |
private String title, message; | |
private OnDismissListener listener; | |
private FragmentManager fragmentManager; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** reading plain text from assets folder */ | |
public static String loadText(Context ctx, String address){ | |
String _data = ""; | |
try{ | |
InputStream is = ctx.getAssets().open(address); | |
int size = is.available(); | |
byte[] buffer = new byt[size]; | |
is.read(buffer); | |
is.close(); | |
_data = new String(buffer); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package fnn.smirl.note.util; | |
import java.util.regex.*; | |
import android.text.*; | |
import android.text.style.*; | |
import android.graphics.*; | |
import java.util.*; | |
public class EditorUtils implements Tokenize { | |
public static void formatEditor(Editable ssb) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.content.Context; | |
import android.speech.tts.TextToSpeech; | |
import android.speech.tts.UtteranceProgressListener; | |
import android.widget.Toast; | |
import java.util.Locale; | |
/*** the implementation of TextToSpeech */ | |
public final class VoiceReadText{ | |
private static TextToSpeech tts; | |
private static boolean READING = false; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.*; | |
/** | |
* For Descriptive Statistics | |
* @AUTHOR: Francis Nduba Numbi | |
* @YEAR: 2017 | |
* | |
* REMEMBER : AFTER ALL DATA HAVE BEEN ADDED, call update(). | |
* else some calculations will be wrong. | |
*/ |