![]() ![]() In addition, you can use the percentage value of a measure in a formula or String meter by using the measure as a Section Variable, with the percentage parameter. The meter will then use the MinValue and MaxValue of the measure to calculate what percentage of that the current value is. While the String meter does not require a percentage when displaying the number value of a measure, it can be told to use the value as a percentage, by using the Percentual option on the meter. Remember, you set this on the measure you are going to use as a percentage, not on the meter that is using it. To address this, you can manually define the range that the measure can be, by setting the MinValue and MaxValue options on the measure. This may not always be the behavior you desire. What Rainmeter will do in this case is to set the MinValue and MaxValue of the measure dynamically, to the smallest and largest values the measure has been since the skin was loaded or refreshed. Examples of this are the NetIn/NetOut/NetTotal measures, SpeedFan, any Calc measures, and any WebParser measures. Other measures do not know themselves what the maximum value the measure can be. There is nothing you need to do for this to work properly. Then you can just use the measure's value in a meter by binding the measure to it with MeasureName=MyMeasure and the percentage will be used in the display of the meter. FreeDiskSpace for instance knows how big the drive you are measuring is, and will set the MinValue to zero, and the MaxValue to the actual size of the drive. Some measures, for example CPU, FreeDiskSpace and Memory, automatically set the minimum and maximum range that the measure can be. This is defined as the MinValue and MaxValue of the measure. The percentage of the total that a measure's current value reflects is based on the "range" that the measure can be. In addition, you may want to display the percentage of the total value a measure is currently at in a String meter, or use the percentage value of a measure in a formula. In order for these meters to know that the current value of the measure is 27%, they need to know what value 100% represents. These would include Bar, Histogram, Line, Rotator and Roundline meters. Some meters require that a measure provide a value that can be used as a percentage. (Otherwise, it is treated as zero.) Likewise, a number value can be displayed or stored to a variable as a string of text, although this may cause the value to lose precision. The Formula option in a Calc measure uses only the number values of other measures, unless section variables are used instead.Īlthough a string value is not a "true" number, it can be used like a number in formulas and options, as long as it contains only numeric characters and valid operators. IfAction options use only the number value of the current measure. The Substitute option affects only the string value of the current measure. When using Section Variables, different syntax is used to refer to a measure's string or number value. When a meter is bound to a measure, it automatically uses the correct value for its type. The article for each measure type explains what is provided for both the number and string values. Depending on the type of measure, these values may be the same, which means you can use them interchangeably or, they may be completely different. Most other measure options depend on the type, but there are some general options that are valid in many or all measures.īelow is an example of a complete working measure: Ī measure actually provides two values: a string, or "raw text," and a number, which can be used in calculation formulas. All measures use the Measure option to define the section as a specific type of measure. FormatĪ measure is written as a section in the skin. These are detailed in their individual articles. Some measure types may have their own special rules. As a section variable, the value is used "literally," which means it does not automatically account for the range or scale.Ī measure can trigger an action when the value passes into a certain range. In this way, the value can be used in almost any meter or measure option. The measure value can be referenced as a section variable. This also takes the measure's range and scale into account (if applicable). In this way, the meter will automatically display the value in a way that is appropriate for the type of meter. The measure simply provides the information as a value, which can be used in several ways:Ī meter can be bound to a measure. Unlike meters, measures do not display anything by themselves. ![]() ![]() Measures are one of the two major kinds of objects in a skin, along with meters. A measure is an object that retrieves information to be used by the skin. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |