iphone Programming Glossary: mtexts
Custom ProgressBar widget http://stackoverflow.com/questions/3841231/custom-progressbar-widget private SeekBar mSlider private Context mContext private int mSize 3 private TextView mTextViews private String mTexts Nafta Gas Gasoil public SliderFrameLayout Context context AttributeSet attrs super context attrs mContext context setWillNotDraw.. TextView mContext tv.setLayoutParams new LayoutParams LayoutParams.WRAP_CONTENT LayoutParams.WRAP_CONTENT tv.setText mTexts i mTextViews i tv addView tv private void addSlider FrameLayout fl new FrameLayout mContext null LayoutParams params new.. object to find what width a particular string would be when drawn on a canvas textWidth int textPaint.measureText mTexts i Then you can iterate over your array of text strings and draw each string in the right place. @Override protected void..
|