1//========================================================================
2//
3// pdfsig.cc
4//
5// This file is licensed under the GPLv2 or later
6//
7// Copyright (C) 2010 Albert Astals Cid <aacid@kde.org>
8//
9//========================================================================
10
11#ifndef NUMBEROFCHARACTERS_H
12#define NUMBEROFCHARACTERS_H
13
14static int numberOfCharacters(unsigned int n)
15{
16 int charNum = 0;
17 while (n >= 10) {
18 n = n / 10;
19 charNum++;
20 }
21 charNum++;
22 return charNum;
23}
24
25#endif
26

source code of poppler/utils/numberofcharacters.h