This is an automated email from the ASF dual-hosted git repository. asf-gitbox-commits pushed a commit to branch openformula in repository https://gitbox.apache.org/repos/asf/openoffice.git
commit efd87262f246367356599e8a0019fda2c631d3d4 Author: Pedro Giffuni <[email protected]> AuthorDate: Sat Nov 14 10:13:51 2026 -0500 docs: Add Help topics for OpenFormula functions IFNA, SKEWP, BITAND, BITOR, BITXOR, BITLSHIFT, BITRSHIFT (Milestone G.1) Create individual help topics (func_*.xhp) for the seven functions introduced in OpenFormula Milestones A and B. Each topic includes description, syntax, parameters, examples, error conditions, and cross-references. Each topic registers a hid/SC_HID_FUNC_* bookmark so Function Wizard Help IDs resolve to the correct topic. Add all seven func_*.xhp files to LINKLINKFILES in main/helpcontent2/util/scalc/makefile.mk so they are included in the Calc Help package build. Correct scfuncs.src Function Wizard metadata for the bitwise functions: 'Positive integer less than 2^48' is inaccurate (zero is valid); use 'Integer greater than or equal to 0 and less than 2^48'. Document that negative shift counts reverse direction in BITLSHIFT/BITRSHIFT. Correct func_skewp.xhp error handling: text and empty cells within referenced ranges are skipped; errors during reference iteration propagate; scalar text arguments cause Err:502 (verified against CalculateSkew() in interpr3.cxx). Add fragment anchors to cross-references (SKEW -> #skew, ISNA -> #isna). Update openformula-milestone-g-sequence.md to mark G.1 Help documentation as complete. --- .../source/text/scalc/01/func_bitand.xhp | 51 ++++++++++++++++++++ .../source/text/scalc/01/func_bitlshift.xhp | 55 ++++++++++++++++++++++ .../source/text/scalc/01/func_bitor.xhp | 51 ++++++++++++++++++++ .../source/text/scalc/01/func_bitrshift.xhp | 55 ++++++++++++++++++++++ .../source/text/scalc/01/func_bitxor.xhp | 51 ++++++++++++++++++++ .../source/text/scalc/01/func_ifna.xhp | 54 +++++++++++++++++++++ .../source/text/scalc/01/func_skewp.xhp | 54 +++++++++++++++++++++ main/helpcontent2/util/scalc/makefile.mk | 7 +++ main/sc/source/ui/src/scfuncs.src | 20 ++++---- odf_docs/openformula-milestone-g-sequence.md | 6 ++- 10 files changed, 392 insertions(+), 12 deletions(-) diff --git a/main/helpcontent2/source/text/scalc/01/func_bitand.xhp b/main/helpcontent2/source/text/scalc/01/func_bitand.xhp new file mode 100644 index 0000000000..9a41a82a31 --- /dev/null +++ b/main/helpcontent2/source/text/scalc/01/func_bitand.xhp @@ -0,0 +1,51 @@ +<?xml version="1.0" encoding="UTF-8"?> + +<!--*********************************************************** + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + ***********************************************************--> + +<helpdocument version="1.0"> +<meta> +<topic id="textscalc01func_bitandxml" indexer="include" status="PUBLISH"> +<title id="tit" xml-lang="en-US">BITAND</title> +<filename>/text/scalc/01/func_bitand.xhp</filename> +</topic> +</meta> +<body> +<bookmark xml-lang="en-US" branch="index" id="bm_id3160201"> +<bookmark_value>BITAND function</bookmark_value> +<bookmark_value>bitwise AND</bookmark_value> +</bookmark> +<bookmark xml-lang="en-US" branch="hid/SC_HID_FUNC_BITAND" id="bm_id3160202" localize="false"/> +<paragraph role="heading" id="hd_id3160201" xml-lang="en-US" level="2" l10n="U"><variable id="bitand"><link href="text/scalc/01/func_bitand.xhp">BITAND</link> +</variable></paragraph> +<paragraph role="paragraph" id="par_id3160203" xml-lang="en-US" l10n="U"><ahelp hid="HID_FUNC_BITAND">Returns the bitwise AND of two integers.</ahelp> Each bit of the result is 1 only if the corresponding bit of both arguments is 1.</paragraph> +<paragraph role="heading" id="hd_id3160204" xml-lang="en-US" level="3" l10n="U">Syntax</paragraph> +<paragraph role="code" id="par_id3160205" xml-lang="en-US" l10n="U">BITAND(Number1; Number2)</paragraph> +<paragraph role="paragraph" id="par_id3160206" xml-lang="en-US" l10n="U"><emph>Number1</emph> and <emph>Number2</emph> are integers greater than or equal to 0 and less than 2^48 (281474976710656).</paragraph> +<paragraph role="heading" id="hd_id3160207" xml-lang="en-US" level="3" l10n="U">Remarks</paragraph> +<paragraph role="paragraph" id="par_id3160208" xml-lang="en-US" l10n="U">Arguments are truncated to integers before the operation. Non-integer, negative, or out-of-range values return an error (Err:502).</paragraph> +<paragraph role="paragraph" id="par_id3160209" xml-lang="en-US" l10n="U">Example: decimal 6 is binary <quote>110</quote>, decimal 3 is binary <quote>011</quote>. BITAND(6; 3) returns 2 (binary <quote>010</quote>).</paragraph> +<paragraph role="heading" id="hd_id3160210" xml-lang="en-US" level="3" l10n="U">Example</paragraph> +<paragraph role="paragraph" id="par_id3160211" xml-lang="en-US" l10n="U"><item type="input">=BITAND(6; 3)</item> returns 2.</paragraph> +<embed href="text/shared/00/00000001.xhp#siehe"/> +<paragraph role="paragraph" id="par_id3160212" xml-lang="en-US" l10n="U"><link href="text/scalc/01/func_bitor.xhp" name="BITOR">BITOR</link>, <link href="text/scalc/01/func_bitxor.xhp" name="BITXOR">BITXOR</link>.</paragraph> +</body> +</helpdocument> diff --git a/main/helpcontent2/source/text/scalc/01/func_bitlshift.xhp b/main/helpcontent2/source/text/scalc/01/func_bitlshift.xhp new file mode 100644 index 0000000000..fd6f1f7f2d --- /dev/null +++ b/main/helpcontent2/source/text/scalc/01/func_bitlshift.xhp @@ -0,0 +1,55 @@ +<?xml version="1.0" encoding="UTF-8"?> + +<!--*********************************************************** + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + ***********************************************************--> + +<helpdocument version="1.0"> +<meta> +<topic id="textscalc01func_bitlshiftxml" indexer="include" status="PUBLISH"> +<title id="tit" xml-lang="en-US">BITLSHIFT</title> +<filename>/text/scalc/01/func_bitlshift.xhp</filename> +</topic> +</meta> +<body> +<bookmark xml-lang="en-US" branch="index" id="bm_id3160501"> +<bookmark_value>BITLSHIFT function</bookmark_value> +<bookmark_value>bitwise left shift</bookmark_value> +</bookmark> +<bookmark xml-lang="en-US" branch="hid/SC_HID_FUNC_BITLSHIFT" id="bm_id3160502" localize="false"/> +<paragraph role="heading" id="hd_id3160501" xml-lang="en-US" level="2" l10n="U"><variable id="bitlshift"><link href="text/scalc/01/func_bitlshift.xhp">BITLSHIFT</link> +</variable></paragraph> +<paragraph role="paragraph" id="par_id3160503" xml-lang="en-US" l10n="U"><ahelp hid="HID_FUNC_BITLSHIFT">Bitwise left shift of an integer value.</ahelp> The bits of <emph>Number</emph> are shifted to the left by <emph>Shift</emph> positions, equivalent to multiplying by 2 raised to the power of <emph>Shift</emph>.</paragraph> +<paragraph role="heading" id="hd_id3160504" xml-lang="en-US" level="3" l10n="U">Syntax</paragraph> +<paragraph role="code" id="par_id3160505" xml-lang="en-US" l10n="U">BITLSHIFT(Number; Shift)</paragraph> +<paragraph role="paragraph" id="par_id3160506" xml-lang="en-US" l10n="U"><emph>Number</emph> is the integer value to be shifted. It must be greater than or equal to 0 and less than 2^48 (281474976710656).</paragraph> +<paragraph role="paragraph" id="par_id3160507" xml-lang="en-US" l10n="U"><emph>Shift</emph> is the number of bit positions to shift. A positive value shifts left; a negative value shifts right (the direction is reversed).</paragraph> +<paragraph role="heading" id="hd_id3160508" xml-lang="en-US" level="3" l10n="U">Remarks</paragraph> +<paragraph role="paragraph" id="par_id3160509" xml-lang="en-US" l10n="U">If <emph>Shift</emph> is 0, <emph>Number</emph> is returned unchanged.</paragraph> +<paragraph role="paragraph" id="par_id3160510" xml-lang="en-US" l10n="U">If <emph>Shift</emph> is greater than or equal to 64 (or less than or equal to -64), the result is 0.</paragraph> +<paragraph role="paragraph" id="par_id3160511" xml-lang="en-US" l10n="U"><emph>Number</emph> is truncated to an integer before the operation. Non-integer, negative, or out-of-range values for <emph>Number</emph>, or non-finite values for <emph>Shift</emph>, return an error (Err:502).</paragraph> +<paragraph role="paragraph" id="par_id3160512" xml-lang="en-US" l10n="U">Example: decimal 1 is binary <quote>1</quote>. BITLSHIFT(1; 2) shifts left by 2, giving binary <quote>100</quote>, which is decimal 4.</paragraph> +<paragraph role="heading" id="hd_id3160513" xml-lang="en-US" level="3" l10n="U">Example</paragraph> +<paragraph role="paragraph" id="par_id3160514" xml-lang="en-US" l10n="U"><item type="input">=BITLSHIFT(1; 2)</item> returns 4.</paragraph> +<paragraph role="paragraph" id="par_id3160515" xml-lang="en-US" l10n="U"><item type="input">=BITLSHIFT(1; -2)</item> returns 0 because a negative shift reverses direction and the value is shifted right, shifting the only bit out.</paragraph> +<embed href="text/shared/00/00000001.xhp#siehe"/> +<paragraph role="paragraph" id="par_id3160516" xml-lang="en-US" l10n="U"><link href="text/scalc/01/func_bitrshift.xhp" name="BITRSHIFT">BITRSHIFT</link>.</paragraph> +</body> +</helpdocument> diff --git a/main/helpcontent2/source/text/scalc/01/func_bitor.xhp b/main/helpcontent2/source/text/scalc/01/func_bitor.xhp new file mode 100644 index 0000000000..cea6319a27 --- /dev/null +++ b/main/helpcontent2/source/text/scalc/01/func_bitor.xhp @@ -0,0 +1,51 @@ +<?xml version="1.0" encoding="UTF-8"?> + +<!--*********************************************************** + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + ***********************************************************--> + +<helpdocument version="1.0"> +<meta> +<topic id="textscalc01func_bitorxml" indexer="include" status="PUBLISH"> +<title id="tit" xml-lang="en-US">BITOR</title> +<filename>/text/scalc/01/func_bitor.xhp</filename> +</topic> +</meta> +<body> +<bookmark xml-lang="en-US" branch="index" id="bm_id3160301"> +<bookmark_value>BITOR function</bookmark_value> +<bookmark_value>bitwise OR</bookmark_value> +</bookmark> +<bookmark xml-lang="en-US" branch="hid/SC_HID_FUNC_BITOR" id="bm_id3160302" localize="false"/> +<paragraph role="heading" id="hd_id3160301" xml-lang="en-US" level="2" l10n="U"><variable id="bitor"><link href="text/scalc/01/func_bitor.xhp">BITOR</link> +</variable></paragraph> +<paragraph role="paragraph" id="par_id3160303" xml-lang="en-US" l10n="U"><ahelp hid="HID_FUNC_BITOR">Returns the bitwise OR of two integers.</ahelp> Each bit of the result is 1 if the corresponding bit of either argument is 1.</paragraph> +<paragraph role="heading" id="hd_id3160304" xml-lang="en-US" level="3" l10n="U">Syntax</paragraph> +<paragraph role="code" id="par_id3160305" xml-lang="en-US" l10n="U">BITOR(Number1; Number2)</paragraph> +<paragraph role="paragraph" id="par_id3160306" xml-lang="en-US" l10n="U"><emph>Number1</emph> and <emph>Number2</emph> are integers greater than or equal to 0 and less than 2^48 (281474976710656).</paragraph> +<paragraph role="heading" id="hd_id3160307" xml-lang="en-US" level="3" l10n="U">Remarks</paragraph> +<paragraph role="paragraph" id="par_id3160308" xml-lang="en-US" l10n="U">Arguments are truncated to integers before the operation. Non-integer, negative, or out-of-range values return an error (Err:502).</paragraph> +<paragraph role="paragraph" id="par_id3160309" xml-lang="en-US" l10n="U">Example: decimal 6 is binary <quote>110</quote>, decimal 3 is binary <quote>011</quote>. BITOR(6; 3) returns 7 (binary <quote>111</quote>).</paragraph> +<paragraph role="heading" id="hd_id3160310" xml-lang="en-US" level="3" l10n="U">Example</paragraph> +<paragraph role="paragraph" id="par_id3160311" xml-lang="en-US" l10n="U"><item type="input">=BITOR(6; 3)</item> returns 7.</paragraph> +<embed href="text/shared/00/00000001.xhp#siehe"/> +<paragraph role="paragraph" id="par_id3160312" xml-lang="en-US" l10n="U"><link href="text/scalc/01/func_bitand.xhp" name="BITAND">BITAND</link>, <link href="text/scalc/01/func_bitxor.xhp" name="BITXOR">BITXOR</link>.</paragraph> +</body> +</helpdocument> diff --git a/main/helpcontent2/source/text/scalc/01/func_bitrshift.xhp b/main/helpcontent2/source/text/scalc/01/func_bitrshift.xhp new file mode 100644 index 0000000000..68a023ba55 --- /dev/null +++ b/main/helpcontent2/source/text/scalc/01/func_bitrshift.xhp @@ -0,0 +1,55 @@ +<?xml version="1.0" encoding="UTF-8"?> + +<!--*********************************************************** + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + ***********************************************************--> + +<helpdocument version="1.0"> +<meta> +<topic id="textscalc01func_bitrshiftxml" indexer="include" status="PUBLISH"> +<title id="tit" xml-lang="en-US">BITRSHIFT</title> +<filename>/text/scalc/01/func_bitrshift.xhp</filename> +</topic> +</meta> +<body> +<bookmark xml-lang="en-US" branch="index" id="bm_id3160601"> +<bookmark_value>BITRSHIFT function</bookmark_value> +<bookmark_value>bitwise right shift</bookmark_value> +</bookmark> +<bookmark xml-lang="en-US" branch="hid/SC_HID_FUNC_BITRSHIFT" id="bm_id3160602" localize="false"/> +<paragraph role="heading" id="hd_id3160601" xml-lang="en-US" level="2" l10n="U"><variable id="bitrshift"><link href="text/scalc/01/func_bitrshift.xhp">BITRSHIFT</link> +</variable></paragraph> +<paragraph role="paragraph" id="par_id3160603" xml-lang="en-US" l10n="U"><ahelp hid="HID_FUNC_BITRSHIFT">Bitwise right shift of an integer value.</ahelp> The bits of <emph>Number</emph> are shifted to the right by <emph>Shift</emph> positions, equivalent to dividing by 2 raised to the power of <emph>Shift</emph>.</paragraph> +<paragraph role="heading" id="hd_id3160604" xml-lang="en-US" level="3" l10n="U">Syntax</paragraph> +<paragraph role="code" id="par_id3160605" xml-lang="en-US" l10n="U">BITRSHIFT(Number; Shift)</paragraph> +<paragraph role="paragraph" id="par_id3160606" xml-lang="en-US" l10n="U"><emph>Number</emph> is the integer value to be shifted. It must be greater than or equal to 0 and less than 2^48 (281474976710656).</paragraph> +<paragraph role="paragraph" id="par_id3160607" xml-lang="en-US" l10n="U"><emph>Shift</emph> is the number of bit positions to shift. A positive value shifts right; a negative value shifts left (the direction is reversed).</paragraph> +<paragraph role="heading" id="hd_id3160608" xml-lang="en-US" level="3" l10n="U">Remarks</paragraph> +<paragraph role="paragraph" id="par_id3160609" xml-lang="en-US" l10n="U">If <emph>Shift</emph> is 0, <emph>Number</emph> is returned unchanged.</paragraph> +<paragraph role="paragraph" id="par_id3160610" xml-lang="en-US" l10n="U">If <emph>Shift</emph> is greater than or equal to 64 (or less than or equal to -64), the result is 0.</paragraph> +<paragraph role="paragraph" id="par_id3160611" xml-lang="en-US" l10n="U"><emph>Number</emph> is truncated to an integer before the operation. Non-integer, negative, or out-of-range values for <emph>Number</emph>, or non-finite values for <emph>Shift</emph>, return an error (Err:502).</paragraph> +<paragraph role="paragraph" id="par_id3160612" xml-lang="en-US" l10n="U">Example: decimal 8 is binary <quote>1000</quote>. BITRSHIFT(8; 2) shifts right by 2, giving binary <quote>10</quote>, which is decimal 2.</paragraph> +<paragraph role="heading" id="hd_id3160613" xml-lang="en-US" level="3" l10n="U">Example</paragraph> +<paragraph role="paragraph" id="par_id3160614" xml-lang="en-US" l10n="U"><item type="input">=BITRSHIFT(8; 2)</item> returns 2.</paragraph> +<paragraph role="paragraph" id="par_id3160615" xml-lang="en-US" l10n="U"><item type="input">=BITRSHIFT(1; -2)</item> returns 4 because a negative shift reverses direction and shifts left by 2.</paragraph> +<embed href="text/shared/00/00000001.xhp#siehe"/> +<paragraph role="paragraph" id="par_id3160616" xml-lang="en-US" l10n="U"><link href="text/scalc/01/func_bitlshift.xhp" name="BITLSHIFT">BITLSHIFT</link>.</paragraph> +</body> +</helpdocument> diff --git a/main/helpcontent2/source/text/scalc/01/func_bitxor.xhp b/main/helpcontent2/source/text/scalc/01/func_bitxor.xhp new file mode 100644 index 0000000000..c7a064eacb --- /dev/null +++ b/main/helpcontent2/source/text/scalc/01/func_bitxor.xhp @@ -0,0 +1,51 @@ +<?xml version="1.0" encoding="UTF-8"?> + +<!--*********************************************************** + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + ***********************************************************--> + +<helpdocument version="1.0"> +<meta> +<topic id="textscalc01func_bitxxml" indexer="include" status="PUBLISH"> +<title id="tit" xml-lang="en-US">BITXOR</title> +<filename>/text/scalc/01/func_bitxor.xhp</filename> +</topic> +</meta> +<body> +<bookmark xml-lang="en-US" branch="index" id="bm_id3160401"> +<bookmark_value>BITXOR function</bookmark_value> +<bookmark_value>bitwise XOR</bookmark_value> +</bookmark> +<bookmark xml-lang="en-US" branch="hid/SC_HID_FUNC_BITXOR" id="bm_id3160402" localize="false"/> +<paragraph role="heading" id="hd_id3160401" xml-lang="en-US" level="2" l10n="U"><variable id="bitxor"><link href="text/scalc/01/func_bitxor.xhp">BITXOR</link> +</variable></paragraph> +<paragraph role="paragraph" id="par_id3160403" xml-lang="en-US" l10n="U"><ahelp hid="HID_FUNC_BITXOR">Returns the bitwise XOR (exclusive OR) of two integers.</ahelp> Each bit of the result is 1 if the corresponding bits of the two arguments differ.</paragraph> +<paragraph role="heading" id="hd_id3160404" xml-lang="en-US" level="3" l10n="U">Syntax</paragraph> +<paragraph role="code" id="par_id3160405" xml-lang="en-US" l10n="U">BITXOR(Number1; Number2)</paragraph> +<paragraph role="paragraph" id="par_id3160406" xml-lang="en-US" l10n="U"><emph>Number1</emph> and <emph>Number2</emph> are integers greater than or equal to 0 and less than 2^48 (281474976710656).</paragraph> +<paragraph role="heading" id="hd_id3160407" xml-lang="en-US" level="3" l10n="U">Remarks</paragraph> +<paragraph role="paragraph" id="par_id3160408" xml-lang="en-US" l10n="U">Arguments are truncated to integers before the operation. Non-integer, negative, or out-of-range values return an error (Err:502).</paragraph> +<paragraph role="paragraph" id="par_id3160409" xml-lang="en-US" l10n="U">Example: decimal 6 is binary <quote>110</quote>, decimal 3 is binary <quote>011</quote>. BITXOR(6; 3) returns 5 (binary <quote>101</quote>).</paragraph> +<paragraph role="heading" id="hd_id3160410" xml-lang="en-US" level="3" l10n="U">Example</paragraph> +<paragraph role="paragraph" id="par_id3160411" xml-lang="en-US" l10n="U"><item type="input">=BITXOR(6; 3)</item> returns 5.</paragraph> +<embed href="text/shared/00/00000001.xhp#siehe"/> +<paragraph role="paragraph" id="par_id3160412" xml-lang="en-US" l10n="U"><link href="text/scalc/01/func_bitand.xhp" name="BITAND">BITAND</link>, <link href="text/scalc/01/func_bitor.xhp" name="BITOR">BITOR</link>.</paragraph> +</body> +</helpdocument> diff --git a/main/helpcontent2/source/text/scalc/01/func_ifna.xhp b/main/helpcontent2/source/text/scalc/01/func_ifna.xhp new file mode 100644 index 0000000000..0f1adaace9 --- /dev/null +++ b/main/helpcontent2/source/text/scalc/01/func_ifna.xhp @@ -0,0 +1,54 @@ +<?xml version="1.0" encoding="UTF-8"?> + +<!--*********************************************************** + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + ***********************************************************--> + +<helpdocument version="1.0"> +<meta> +<topic id="textscalc01func_ifnaxml" indexer="include" status="PUBLISH"> +<title id="tit" xml-lang="en-US">IFNA</title> +<filename>/text/scalc/01/func_ifna.xhp</filename> +</topic> +</meta> +<body> +<bookmark xml-lang="en-US" branch="index" id="bm_id3160001"> +<bookmark_value>IFNA function</bookmark_value> +<bookmark_value>error handling;IFNA</bookmark_value> +<bookmark_value>#N/A;IFNA</bookmark_value> +</bookmark> +<bookmark xml-lang="en-US" branch="hid/SC_HID_FUNC_IFNA" id="bm_id3160002" localize="false"/> +<paragraph role="heading" id="hd_id3160001" xml-lang="en-US" level="2" l10n="U"><variable id="ifna"><link href="text/scalc/01/func_ifna.xhp">IFNA</link> +</variable></paragraph> +<paragraph role="paragraph" id="par_id3160003" xml-lang="en-US" l10n="U"><ahelp hid="HID_FUNC_IFNA">Returns the value if the cell does not contain an #N/A error value, otherwise it returns the alternative value.</ahelp> Only the #N/A error is substituted; all other error values and ordinary values pass through unchanged.</paragraph> +<paragraph role="heading" id="hd_id3160004" xml-lang="en-US" level="3" l10n="U">Syntax</paragraph> +<paragraph role="code" id="par_id3160005" xml-lang="en-US" l10n="U">IFNA(Value; Alternative)</paragraph> +<paragraph role="paragraph" id="par_id3160006" xml-lang="en-US" l10n="U"><emph>Value</emph> is the value or reference to be checked for an #N/A error.</paragraph> +<paragraph role="paragraph" id="par_id3160007" xml-lang="en-US" l10n="U"><emph>Alternative</emph> is the value returned when <emph>Value</emph> produces an #N/A error. It is evaluated only when <emph>Value</emph> is #N/A.</paragraph> +<paragraph role="heading" id="hd_id3160008" xml-lang="en-US" level="3" l10n="U">Remarks</paragraph> +<paragraph role="paragraph" id="par_id3160009" xml-lang="en-US" l10n="U">IFNA distinguishes #N/A from other error values. Other errors (for example Err:502, Err:508, or DIV/0!) are not caught and are returned as-is.</paragraph> +<paragraph role="paragraph" id="par_id3160010" xml-lang="en-US" l10n="U">When <emph>Value</emph> is a matrix, only matrix elements containing #N/A are replaced by <emph>Alternative</emph>; all other elements pass through unchanged.</paragraph> +<paragraph role="heading" id="hd_id3160011" xml-lang="en-US" level="3" l10n="U">Example</paragraph> +<paragraph role="paragraph" id="par_id3160012" xml-lang="en-US" l10n="U"><item type="input">=IFNA(VLOOKUP("zzz";A1:B10;2;0); "Not found")</item> returns <quote>Not found</quote> when the lookup value is not present and produces #N/A.</paragraph> +<paragraph role="paragraph" id="par_id3160013" xml-lang="en-US" l10n="U"><item type="input">=IFNA(1/0; 0)</item> returns Err:502 (division by zero) because IFNA does not catch errors other than #N/A.</paragraph> +<embed href="text/shared/00/00000001.xhp#siehe"/> +<paragraph role="paragraph" id="par_id3160014" xml-lang="en-US" l10n="U"><link href="text/scalc/01/04060104.xhp#isna" name="ISNA">ISNA</link>.</paragraph> +</body> +</helpdocument> diff --git a/main/helpcontent2/source/text/scalc/01/func_skewp.xhp b/main/helpcontent2/source/text/scalc/01/func_skewp.xhp new file mode 100644 index 0000000000..05b65fd971 --- /dev/null +++ b/main/helpcontent2/source/text/scalc/01/func_skewp.xhp @@ -0,0 +1,54 @@ +<?xml version="1.0" encoding="UTF-8"?> + +<!--*********************************************************** + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + ***********************************************************--> + +<helpdocument version="1.0"> +<meta> +<topic id="textscalc01func_skewpxml" indexer="include" status="PUBLISH"> +<title id="tit" xml-lang="en-US">SKEWP</title> +<filename>/text/scalc/01/func_skewp.xhp</filename> +</topic> +</meta> +<body> +<bookmark xml-lang="en-US" branch="index" id="bm_id3160101"> +<bookmark_value>SKEWP function</bookmark_value> +<bookmark_value>skewness;population</bookmark_value> +<bookmark_value>population skewness</bookmark_value> +</bookmark> +<bookmark xml-lang="en-US" branch="hid/SC_HID_FUNC_SKEWP" id="bm_id3160102" localize="false"/> +<paragraph role="heading" id="hd_id3160101" xml-lang="en-US" level="2" l10n="U"><variable id="skewp"><link href="text/scalc/01/func_skewp.xhp">SKEWP</link> +</variable></paragraph> +<paragraph role="paragraph" id="par_id3160103" xml-lang="en-US" l10n="U"><ahelp hid="HID_FUNC_SKEWP">Returns the skewness of a distribution using the population standard deviation.</ahelp> Skewness characterizes the degree of asymmetry of a distribution around its mean.</paragraph> +<paragraph role="heading" id="hd_id3160104" xml-lang="en-US" level="3" l10n="U">Syntax</paragraph> +<paragraph role="code" id="par_id3160105" xml-lang="en-US" l10n="U">SKEWP(Number1; Number2; ...Number30)</paragraph> +<paragraph role="paragraph" id="par_id3160106" xml-lang="en-US" l10n="U"><emph>Number1, Number2, ... Number30</emph> are up to 30 numerical values or ranges representing the entire population.</paragraph> +<paragraph role="heading" id="hd_id3160107" xml-lang="en-US" level="3" l10n="U">Remarks</paragraph> +<paragraph role="paragraph" id="par_id3160108" xml-lang="en-US" l10n="U">SKEWP calculates <emph>population</emph> skewness, using the population standard deviation (dividing by N). Use <link href="text/scalc/01/04060185.xhp#skew" name="SKEW">SKEW</link> for <emph>sample</emph> skewness, which uses the sample standard deviation (dividing by N-1).</paragraph> +<paragraph role="paragraph" id="par_id3160109" xml-lang="en-US" l10n="U">Text and empty cells within referenced ranges are skipped. Errors encountered during reference iteration propagate and cause the function to return an error. Scalar text arguments cause an error (Err:502). At least one numeric value is required.</paragraph> +<paragraph role="paragraph" id="par_id3160110" xml-lang="en-US" l10n="U">If the population variance is zero (for example, all values are identical, or only one value is given), the result is undefined and the function returns an error.</paragraph> +<paragraph role="heading" id="hd_id3160111" xml-lang="en-US" level="3" l10n="U">Example</paragraph> +<paragraph role="paragraph" id="par_id3160112" xml-lang="en-US" l10n="U"><item type="input">=SKEWP(1; 2; 3; 4; 5)</item> returns approximately <item type="input">0</item> because the distribution is symmetric.</paragraph> +<paragraph role="paragraph" id="par_id3160113" xml-lang="en-US" l10n="U"><item type="input">=SKEWP(1; 1; 1; 2; 3)</item> returns a positive value because the distribution has a longer tail toward higher values.</paragraph> +<embed href="text/shared/00/00000001.xhp#siehe"/> +<paragraph role="paragraph" id="par_id3160114" xml-lang="en-US" l10n="U"><link href="text/scalc/01/04060185.xhp#skew" name="SKEW">SKEW</link>.</paragraph> +</body> +</helpdocument> diff --git a/main/helpcontent2/util/scalc/makefile.mk b/main/helpcontent2/util/scalc/makefile.mk index 89c6db165b..f5de336e03 100644 --- a/main/helpcontent2/util/scalc/makefile.mk +++ b/main/helpcontent2/util/scalc/makefile.mk @@ -236,6 +236,13 @@ LINKLINKFILES= \ text$/scalc$/01$/func_workday.xhp \ text$/scalc$/01$/func_year.xhp \ text$/scalc$/01$/func_yearfrac.xhp \ + text$/scalc$/01$/func_bitand.xhp \ + text$/scalc$/01$/func_bitlshift.xhp \ + text$/scalc$/01$/func_bitrshift.xhp \ + text$/scalc$/01$/func_bitor.xhp \ + text$/scalc$/01$/func_bitxor.xhp \ + text$/scalc$/01$/func_ifna.xhp \ + text$/scalc$/01$/func_skewp.xhp \ text$/scalc$/01$/solver.xhp \ text$/scalc$/01$/solver_options.xhp \ text$/scalc$/01$/text2columns.xhp \ diff --git a/main/sc/source/ui/src/scfuncs.src b/main/sc/source/ui/src/scfuncs.src index ec6ff81ad7..93cc3e0448 100644 --- a/main/sc/source/ui/src/scfuncs.src +++ b/main/sc/source/ui/src/scfuncs.src @@ -9509,7 +9509,7 @@ Resource RID_SC_FUNCTION_DESCRIPTIONS2 }; String 3 // Description of Parameter 1 { - Text [ en-US ] = "Positive integer less than 2^48." ; + Text [ en-US ] = "Integer greater than or equal to 0 and less than 2^48 (281474976710656)." ; }; String 4 // Name of Parameter 2 { @@ -9517,7 +9517,7 @@ Resource RID_SC_FUNCTION_DESCRIPTIONS2 }; String 5 // Description of Parameter 2 { - Text [ en-US ] = "Positive integer less than 2^48." ; + Text [ en-US ] = "Integer greater than or equal to 0 and less than 2^48 (281474976710656)." ; }; }; @@ -9542,7 +9542,7 @@ Resource RID_SC_FUNCTION_DESCRIPTIONS2 }; String 3 // Description of Parameter 1 { - Text [ en-US ] = "Positive integer less than 2^48." ; + Text [ en-US ] = "Integer greater than or equal to 0 and less than 2^48 (281474976710656)." ; }; String 4 // Name of Parameter 2 { @@ -9550,7 +9550,7 @@ Resource RID_SC_FUNCTION_DESCRIPTIONS2 }; String 5 // Description of Parameter 2 { - Text [ en-US ] = "Positive integer less than 2^48." ; + Text [ en-US ] = "Integer greater than or equal to 0 and less than 2^48 (281474976710656)." ; }; }; @@ -9575,7 +9575,7 @@ Resource RID_SC_FUNCTION_DESCRIPTIONS2 }; String 3 // Description of Parameter 1 { - Text [ en-US ] = "Positive integer less than 2^48." ; + Text [ en-US ] = "Integer greater than or equal to 0 and less than 2^48 (281474976710656)." ; }; String 4 // Name of Parameter 2 { @@ -9583,7 +9583,7 @@ Resource RID_SC_FUNCTION_DESCRIPTIONS2 }; String 5 // Description of Parameter 2 { - Text [ en-US ] = "Positive integer less than 2^48." ; + Text [ en-US ] = "Integer greater than or equal to 0 and less than 2^48 (281474976710656)." ; }; }; @@ -9607,7 +9607,7 @@ Resource RID_SC_FUNCTION_DESCRIPTIONS2 }; String 3 // Description of Parameter 1 { - Text [ en-US ] = "The value to be shifted. Positive integer." ; + Text [ en-US ] = "The value to be shifted. Integer greater than or equal to 0 and less than 2^48 (281474976710656)." ; }; String 4 // Name of Parameter 2 { @@ -9615,7 +9615,7 @@ Resource RID_SC_FUNCTION_DESCRIPTIONS2 }; String 5 // Description of Parameter 2 { - Text [ en-US ] = "The number of bits the first argument is to be shifted by." ; + Text [ en-US ] = "The number of bit positions the first argument is shifted by. A positive value shifts left; a negative value shifts right." ; }; }; @@ -9639,7 +9639,7 @@ Resource RID_SC_FUNCTION_DESCRIPTIONS2 }; String 3 // Description of Parameter 1 { - Text [ en-US ] = "The value to be shifted. Positive integer." ; + Text [ en-US ] = "The value to be shifted. Integer greater than or equal to 0 and less than 2^48 (281474976710656)." ; }; String 4 // Name of Parameter 2 { @@ -9647,7 +9647,7 @@ Resource RID_SC_FUNCTION_DESCRIPTIONS2 }; String 5 // Description of Parameter 2 { - Text [ en-US ] = "The number of bits the first argument is to be shifted by." ; + Text [ en-US ] = "The number of bit positions the first argument is shifted by. A positive value shifts right; a negative value shifts left." ; }; }; diff --git a/odf_docs/openformula-milestone-g-sequence.md b/odf_docs/openformula-milestone-g-sequence.md index 8a5afa2fec..36400159da 100644 --- a/odf_docs/openformula-milestone-g-sequence.md +++ b/odf_docs/openformula-milestone-g-sequence.md @@ -9,7 +9,7 @@ | Phase | Status | Commit | Notes | |---|---|---|---| -| G.1 | Complete | `41da3628f9` | STRING_MAXLEN documented; ScDBCount empty-cell TODO investigated | +| G.1 | Complete | `41da3628f9` + Help topics commit | STRING_MAXLEN documented; ScDBCount empty-cell TODO investigated; Help topics added for IFNA, SKEWP, BITAND, BITOR, BITXOR, BITLSHIFT, BITRSHIFT | | G.2 | Investigated (not implemented) | — | Fix approach documented; requires AOO build/test environment | | G.3 | Pending | — | Decision record needed before any code change | | G.4 | Pending | — | Corpus regression analysis needed | @@ -38,6 +38,7 @@ These items require no production source modification and can be completed immed | G.1.1 | F-GAP-008 | Basic Limits — strings | Locate `STRING_MAXLEN` definition; confirm value >= 32767 or document actual limit | Static lookup; no code change | Complete — `main/tools/inc/tools/string.hxx:110-120`; default `STRING_MAXLEN = 65,535` (0xFFFF without STRING32), exceeds ODF 1.4 32,767 minimum | | G.1.2 | F-GAP-012 | Syntax — named expressions | Document named expression test requirement (pre-defined `MYNAME` not available in calcval harness) | Test infrastructure note | Complete — documented in F-GAP-012; SYN-009-named marked not directly executable | | G.1.3 | F-GAP-015 | COUNTA/COUNTBLANK | Document scalar `""` vs formula-cell `""` distinction as implementation-defined | Audit documentation | Complete — documented in F-GAP-001, F-GAP-002, F-GAP-015 | +| G.1.4 | — | Help documentation | Add Help topics for IFNA, SKEWP, BITAND, BITOR, BITXOR, BITLSHIFT, BITRSHIFT; verify HID_FUNC_* → topic mapping | `main/helpcontent2/source/text/scalc/01/func_*.xhp` (7 files) + `scfuncs.src` metadata | Complete — Help topics created, Function Wizard HIDs resolve, scfuncs.src descriptions corrected | ## Phase G.2 — Investigation Complete: Criteria Syntax Empty-Cell Fix (ScDBCount) @@ -125,7 +126,8 @@ G.4 (INDEX compatibility) ──┘ └ ## Definition of Done for Milestone G -- All G.1 documentation items complete (committed at `41da3628f9`) +- All G.1 documentation items complete (committed at `41da3628f9`; Help topics for 7 functions committed separately) +- G.1 Help topics: IFNA, SKEWP, BITAND, BITOR, BITXOR, BITLSHIFT, BITRSHIFT — all HID_FUNC_* IDs resolve to topics, discoverable via Help index/search - G.2 ScDBCount empty-cell fix approach documented (blocked: no build/test environment) - G.3 COUNTBLANK behavior: decision record required before any code change - G.4 INDEX compatibility: corpus regression analysis required before compatibility option
