VR-Forces 4.0.4 Class Documentation
include/tdbutil/translation.h
Go to the documentation of this file.
00001 /*******************************************************************************
00002 ** Copyright (c) 2005 MAK Technologies, Inc.
00003 ** All rights reserved.
00004 *******************************************************************************/
00005 /*******************************************************************************
00006 ** $RCSfile: translation.h,v $ $Revision: 1.4 $ $State: Exp $
00007 *******************************************************************************/
00008 
00009 #ifndef DTTRANSLATION_H_
00010 #define DTTRANSLATION_H_
00011 
00012 #include <vlutil/vlString.h>
00013 #include <matrix/vlVector.h>
00014 
00015 #include "tdbutil/tdbUtilDefines.h"
00016 
00017 // Set the global translation function to handle your own custom translations
00018 typedef DtString (*DtTranslatorFunction)(const char* text, const char* module);
00019 
00020 DT_DLL_tdbutil DtString trUtf8(const char* text, const char* module);
00021 DT_DLL_tdbutil void setTranslatorFunction(DtTranslatorFunction);
00022 
00023 // Pretty formatting for back-end tasks and sets
00024 
00025 class DT_DLL_tdbutil DtUnitFormatter
00026 {
00027 public:
00028    virtual DtString formatSourceToDisplay(const DtVector& val) const;
00029    virtual DtString formatSourceToDisplay(double val, const DtString& unitDisplay,
00030                                               const DtString& source, DtString& unitLabel) const;
00031 };
00032 
00033 DT_DLL_tdbutil DtUnitFormatter* setUnitFormatter(DtUnitFormatter*);
00034 
00035 // Assumes that DtVector is in geocentric
00036 DT_DLL_tdbutil DtString formatSourceToDisplay(const DtVector& val);
00037 
00038 // value must be in source units as defined in tdbUnits.h
00039 DT_DLL_tdbutil DtString formatSourceToDisplay(double val, const DtString& unitDisplay,
00040                                               const DtString& source, DtString& unitLabel);
00041 
00042 #endif

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)