/elec/propeller-clock

To get this branch, use:
bzr branch http://bzr.ed.am/elec/propeller-clock

« back to all changes in this revision

Viewing changes to src/text_renderer.cc

  • Committer: edam
  • Date: 2012-03-20 22:13:38 UTC
  • Revision ID: tim@ed.am-20120320221338-4zvmyesujc0zwwsx
updated arduino makefile

Show diffs side-by-side

added added

removed removed

25
25
#include "Arduino.h"
26
26
#include <avr/pgmspace.h>
27
27
#include "common.h"
28
 
#include "nvram.h"
29
28
 
30
29
 
31
30
// cached glyph
351
350
}
352
351
 
353
352
 
354
 
void TextRenderer::init()
355
 
{
356
 
        Nvram::load( Nvram::NVRAM_FONT, _font );
357
 
        if( _font < 0 || _font >= 4 ) _font = 0;
358
 
}
359
 
 
360
 
 
361
353
int TextRenderer::get_width( int message_len )
362
354
{
363
355
        return message_len * 8 * TEXT_SCALE;
435
427
{
436
428
        if( ++_font >= 4 )
437
429
                _font = 0;
438
 
        Nvram::save( Nvram::NVRAM_FONT, _font );
439
430
}